aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkPostConfig.h
Commit message (Collapse)AuthorAge
* eliminate SK_BUILD_FOR_WIN32Gravatar Mike Klein2018-01-26
| | | | | | | | | | SK_BUILD_FOR_WIN and SK_BUILD_FOR_WIN32 have long meant the same thing. Chrome fix is https://chromium-review.googlesource.com/c/chromium/src/+/884007 Change-Id: I0e907b1bcd2a358eabf776f414fd3aeb3c689561 Reviewed-on: https://skia-review.googlesource.com/99340 Reviewed-by: Mike Reed <reed@google.com>
* GOOGLE3 -> SK_BUILD_FOR_GOOGLE3Gravatar Mike Klein2017-12-19
| | | | | | | | | | | | | This is more consistent with our other SK_BUILD_FOR_... macros, and less likely to collide with other preprocessor logic. (Luckily, this was defined in public.bzl, so we can do this all in one CL in the Skia repo.) Change-Id: I5f232888288c9c53fad445545d983d0fb0b4add8 Reviewed-on: https://skia-review.googlesource.com/86940 Reviewed-by: Mike Klein <mtklein@chromium.org> Commit-Queue: Mike Klein <mtklein@chromium.org>
* turn on extended Clang warnings on Windows tooGravatar Chris Dalton2017-12-04
| | | | | | | | | | Plus some small rearrangements of the various warning lists. Change-Id: Ied58f940341d69ddab971a529fd01b1e96b65641 Reviewed-on: https://skia-review.googlesource.com/67720 Commit-Queue: Chris Dalton <csmartdalton@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Revert "Revert "Add Atlas Text interface for rendering SDF glyphs.""Gravatar Brian Salomon2017-11-19
| | | | | | | | | | This reverts commit 9c2202ffc22b4293b48a4edeafa1b5d2bab8bb83. Bug: skia: Change-Id: I482ddf74f8e40d3d0908c840ba5c6ff981ccefbd Reviewed-on: https://skia-review.googlesource.com/73345 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Revert "Add Atlas Text interface for rendering SDF glyphs."Gravatar Greg Daniel2017-11-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 39631f3df172feb385527a5d125bc53b0bded7e6. Reason for revert: break google3 rool Original change's description: > Add Atlas Text interface for rendering SDF glyphs. > > This new API is built upon SDF text atlas code from the GPU backend. Unlike using the GPU > backend to draw text, this set of interfaces allows the client to render the SDF glyphs. The > client issues text draws to potentially multiple targets and then the client flushes. The > client then gets commands from Skia with data to put into a texture atlas and vertices to > draw that reference the texture. The client is responsible for creating the texture, uploading > the SDF data to the texture, and drawing the vertices provided by Skia. > > Change-Id: Ie9447e19b85f0ce1c2b942e5216c787a74f335d3 > Reviewed-on: https://skia-review.googlesource.com/59360 > Commit-Queue: Brian Salomon <bsalomon@google.com> > Reviewed-by: Robert Phillips <robertphillips@google.com> TBR=jvanverth@google.com,bsalomon@google.com,robertphillips@google.com Change-Id: I4aad0c99e645b476fd8ba25731f2a10e8802bb25 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/73420 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Add Atlas Text interface for rendering SDF glyphs.Gravatar Brian Salomon2017-11-17
| | | | | | | | | | | | | | This new API is built upon SDF text atlas code from the GPU backend. Unlike using the GPU backend to draw text, this set of interfaces allows the client to render the SDF glyphs. The client issues text draws to potentially multiple targets and then the client flushes. The client then gets commands from Skia with data to put into a texture atlas and vertices to draw that reference the texture. The client is responsible for creating the texture, uploading the SDF data to the texture, and drawing the vertices provided by Skia. Change-Id: Ie9447e19b85f0ce1c2b942e5216c787a74f335d3 Reviewed-on: https://skia-review.googlesource.com/59360 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* clang on windows supportGravatar Mike Klein2017-07-31
| | | | | | | | | | | | | | | | | 1) Run python bin/fetch-clang-win 2) Set clang_win = "../bin/clang_win" 3) ??? 4) Profit Most changes here are to pass the right -mfoo flags to Clang to enable advanced instruction sets, or fixed warning-as-errors. BUG=skia:2679 Change-Id: Ieed145d35c209131c7c16fdd3ee11a3de4a1a921 Reviewed-on: https://skia-review.googlesource.com/28740 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
* GR_TEST_UTILS fixesGravatar Brian Salomon2017-07-06
| | | | | | | | | | | | | | Fixes build of Skia lib when GR_TEST_UTILS=0 Makes GR_TEST_UTILS=0 for official builds Makes "Mini" builder bot exercise building GPU with is_official_build=true Bug: skia:6786 Change-Id: I6186683a3a216d2e779645bd9e8276a66bcff4d5 Reviewed-on: https://skia-review.googlesource.com/21524 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Brian Osman <brianosman@google.com>
* fix SkASSERT for Visual StudioGravatar Cary Clark2017-05-11
| | | | | | | | | | | | | | Changing colons to parens permits the error to be recognized, so that clicking on it goes to the source line with the assert. R=reed@google.com Change-Id: Ifec7fc0633e8ecf0f670418fefaf8ca87ee3d498 Reviewed-on: https://skia-review.googlesource.com/16485 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Cary Clark <caryclark@skia.org>
* drawfilter is legacy-guarded, no need for deprecatedGravatar Mike Reed2017-05-03
| | | | | | | | Bug: skia: Change-Id: Ic8dbe9aa043bd793e49975f5b6f08a0ac38e4faa Reviewed-on: https://skia-review.googlesource.com/15185 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Use alignas to force alignment.Gravatar herb2016-11-04
| | | | | | | | | | | | | | | | Using alignas reduces code and platform specific macros. Use alignas instead of std::aligned_storage because it is unimplemneted in MSVC 2015. Here is the bug from MS: https://connect.microsoft.com/VisualStudio/feedback/details/1559873/std-aligned-storage-cannot-align-type-with-16-byte BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2468243002 TBR=reed@google.com Review-Url: https://codereview.chromium.org/2473143002
* Revert of Try to use only std::aligned_storage. (patchset #2 id:20001 of ↵Gravatar benjaminwagner2016-11-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/2468243002/ ) Reason for revert: DM failure: https://luci-milo.appspot.com/swarming/task/324387bf30100f10 c:\b\work\skia\src\core\sklinearbitmappipeline.cpp:49: fatal error: "assert(sizeof(Variant) <= sizeof(fSpace))" Original issue's description: > Try to use only std::aligned_storage. This does not change the API. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2468243002 > TBR=reed@google.com > > Committed: https://skia.googlesource.com/skia/+/e736e0c2d52a29a3b88a29ab39b3a90a5a2443a0 TBR=mtklein@chromium.org,bsalomon@google.com,mtklein@google.com,reed@google.com,herb@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2474073002
* Try to use only std::aligned_storage. This does not change the API.Gravatar herb2016-11-03
| | | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2468243002 TBR=reed@google.com Review-Url: https://codereview.chromium.org/2468243002
* SkPDF: Glyph validation changeGravatar halcanary2016-08-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of mapping invaid glyphIDs to zero or maxGlyphID, don't draw them at all. Validate glyphs when glyph is written, not ahead of time. Don't allocate array to copy user-provided glyphs. Easy early exit from SkPDFDevice::internalDrawText() GlyphPositioner::flush() called ~GlyphPositioner() SkScopeExit class now exists. Assume SkTypeface* pointers are now never null in more places. precalculate alignmentFactor to clean up code. SkPDFDevice::updateFont must be called with validated glyphID. Skip bad glyphs to make this true. SkPDFDevice::updateFont always succeeds. SkPDFFont::GetFontResource always succeeds (preconditions are asserted). If GetMetrics fails, don't call GetFontResource. SkPDFFont::glyphsToPDFFontEncodingCount() becomes SkPDFFont::countStretch() and is inlined. SkPDFFont::glyphsToPDFFontEncoding now works one Glyph at a time and is inlined. SkPDFFont::noteGlyphUsage() operates one glyph at a time. Add SkScopeExit.h; also a unit test for it. SkPostConfig: Fix SK_UNUSED for Win32. No public API changes. TBR=reed@google.com BUG=625995 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2278703002 Review-Url: https://codereview.chromium.org/2278703002
* Optimized implementation of quickReject()Gravatar msarett2016-08-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Impl Overview (1) Keep the device clip bounds up to date. This requires minimal additional work in a few places throughout canvas. (2) Keep track of if the ctm isScaleTranslate. Yes, there's a function that does this, but it's slow to call. (3) Perform the src->device transform in quick reject, then check intersection/nan. Other Notes: (1) NaN and intersection checks are performed simultaneously. (2) We no longer quick reject infinity. (3) Affine and perspective are both handled in the slow case. (4) SkRasterClip::isEmpty() is handled by the intersection check. Performance on Nexus 6P: 93.2ms -> 59.8ms Overall Android Jank Tests Performance Impact: Should gain us a ms or two on some tests. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2225393002 Committed: https://skia.googlesource.com/skia/+/d22a817ff57986407facd16af36320fc86ce02da Review-Url: https://codereview.chromium.org/2225393002
* Revert of Optimized implementation of quickReject() (patchset #12 id:260001 ↵Gravatar mtklein2016-08-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of https://codereview.chromium.org/2225393002/ ) Reason for revert: New assert triggering in the Chrome roll, https://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_asan_rel_ng/builds/208750/steps/webkit_unit_tests%20%28with%20patch%29%20on%20Ubuntu-12.04/logs/FrameThrottlingTest.SynchronousLayoutInAnimationFrameCallback and breaks the SKNX_NO_SIMD bot, https://codereview.chromium.org/2236363004 Original issue's description: > Optimized implementation of quickReject() > > Impl Overview > (1) Keep the device clip bounds up to date. This > requires minimal additional work in a few places > throughout canvas. > (2) Keep track of if the ctm isScaleTranslate. Yes, > there's a function that does this, but it's slow > to call. > (3) Perform the src->device transform in quick reject, > then check intersection/nan. > > Other Notes: > (1) NaN and intersection checks are performed > simultaneously. > (2) We no longer quick reject infinity. > (3) Affine and perspective are both handled in the slow > case. > (4) SkRasterClip::isEmpty() is handled by the intersection > check. > > Performance on Nexus 6P: > 93.2ms -> 59.8ms > > Overall Android Jank Tests Performance Impact: > Should gain us a ms or two on some tests. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2225393002 > > Committed: https://skia.googlesource.com/skia/+/d22a817ff57986407facd16af36320fc86ce02da TBR=reed@google.com,herb@google.com,msarett@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2231393003
* Optimized implementation of quickReject()Gravatar msarett2016-08-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Impl Overview (1) Keep the device clip bounds up to date. This requires minimal additional work in a few places throughout canvas. (2) Keep track of if the ctm isScaleTranslate. Yes, there's a function that does this, but it's slow to call. (3) Perform the src->device transform in quick reject, then check intersection/nan. Other Notes: (1) NaN and intersection checks are performed simultaneously. (2) We no longer quick reject infinity. (3) Affine and perspective are both handled in the slow case. (4) SkRasterClip::isEmpty() is handled by the intersection check. Performance on Nexus 6P: 93.2ms -> 59.8ms Overall Android Jank Tests Performance Impact: Should gain us a ms or two on some tests. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2225393002 Review-Url: https://codereview.chromium.org/2225393002
* Enable SK_DEBUG/SK_RELEASE to be defined in the user config.Gravatar djsollen2016-08-05
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2204683005 Review-Url: https://codereview.chromium.org/2204683005
* Default fake gamma to sRGB.Gravatar mtklein2016-08-01
| | | | | | | | | | | | | No one appears to be using the default 2.2. This makes SK_GAMMA_SRGB the default / a no-op, which seems more realistic. Chrome's explicitly setting SK_GAMMA_EXPONENT or SK_GAMMA_SRGB. We set Android platform explicitly to 1.4. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2198073002 Review-Url: https://codereview.chromium.org/2198073002
* Improve assert reporting.Gravatar bungeman2016-07-20
| | | | | | | | | | | Make SkASSERTF output readable. Ensure the assert predicate is stringified once. Make the abort code consistent. TBR=reed This doesn't change any public API, most of this should be privatized. Review-Url: https://codereview.chromium.org/2161103002
* centralize VECTORCALL as SK_VECTORCALLGravatar mtklein2016-07-07
| | | | | | | | | | | | Gonna start using this, might as well define it once centrally. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2126253002 No public API changes. TBR=reed@google.com Review-Url: https://codereview.chromium.org/2126253002
* SkLeanWindows.h: #include "Windows.h" fewer placesGravatar halcanary2016-06-07
| | | | | | | | | | | | | | | | | | | | | | | | $ git grep -l '<windows.h>' include src include/private/SkLeanWindows.h $ git grep -l SkLeanWindows.h | grep '\.h$' include/ports/SkTypeface_win.h include/utils/win/SkHRESULT.h include/utils/win/SkTScopedComPtr.h include/views/SkEvent.h src/core/SkMathPriv.h src/ports/SkTypeface_win_dw.h src/utils/SkThreadUtils_win.h src/utils/win/SkWGL.h The same for `#include <intrin.h>` that was found in SkMath.h. Those functions that needed it are moved to SkMathPriv.h. GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2041943002 CQ_INCLUDE_TRYBOTS=tryserver.chromium.win:win_chromium_compile_dbg_ng,win_chromium_compile_rel_ng Review-Url: https://codereview.chromium.org/2041943002
* Skia Filter Quality and Scaling MetricsGravatar ericrk2016-04-18
| | | | | | | | | | | | | | | | Adds histogram metrics to log the filter quality and scale factor of each image draw. To make the data easier to consume, this is broken down into a number of individual histograms: - Filter quality across all draw calls - Scale amount across all draw calls - Scale amount per filter quality (4 histograms total) BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1686203002 Committed: https://skia.googlesource.com/skia/+/f57b3a6e4a002caf01378832cbd756c6c163a783 Review URL: https://codereview.chromium.org/1686203002
* Revert of Skia Filter Quality and Scaling Metrics (patchset #3 id:60001 of ↵Gravatar ericrk2016-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1686203002/ ) Reason for revert: reverting this to address Ilya's comments. Original issue's description: > Skia Filter Quality and Scaling Metrics > > Adds histogram metrics to log the filter quality and scale factor of > each image draw. To make the data easier to consume, this is broken > down into a number of individual histograms: > - Filter quality across all draw calls > - Scale amount across all draw calls > - Scale amount per filter quality (4 histograms total) > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1686203002 > > Committed: https://skia.googlesource.com/skia/+/f57b3a6e4a002caf01378832cbd756c6c163a783 TBR=bsalomon@google.com,isherman@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1735423002
* Skia Filter Quality and Scaling MetricsGravatar ericrk2016-02-25
| | | | | | | | | | | | | | Adds histogram metrics to log the filter quality and scale factor of each image draw. To make the data easier to consume, this is broken down into a number of individual histograms: - Filter quality across all draw calls - Scale amount across all draw calls - Scale amount per filter quality (4 histograms total) BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1686203002 Review URL: https://codereview.chromium.org/1686203002
* Add Histogram Macros to SkiaGravatar ericrk2016-02-05
| | | | | | | | | | | | | | | | | | | | | | | | Adds a set of histogram macros to Skia, modeled after Chrome's UMA_HISTOGRAM_* macros. These allow logging of high frequency events, and are useful to analyze real world usage of certain features. By default, these macros are no-ops. Users can provide a custom header file which defines these macros if they wish to collect histogram data. Chrome will provide such a header. I've currently only added two macros: - SK_HISTOGRAM_BOOLEAN - logs a true/false type relationship (whether we are tiling a texture or not on each draw). - SK_HISTOGRAM_ENUMERATION - logs a set of potential values (which of a number of choices were selected for the texture upload path). We could add more unused macros at the moment, but it seems easier to add these as needed, WDYT? BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1652053004 Review URL: https://codereview.chromium.org/1652053004
* Consolidate SK_CRASH and sk_throw into SK_ABORTGravatar djsollen2016-01-29
| | | | | | | TBR=reed@google.com GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1648343003 Review URL: https://codereview.chromium.org/1648343003
* Revert of Consolidate SK_CRASH and sk_throw into SK_ABORT (patchset #5 ↵Gravatar djsollen2016-01-22
| | | | | | | | | | | | | | | | | | | | | id:80001 of https://codereview.chromium.org/1610823002/ ) Reason for revert: Chrome is calling SK_CRASH Original issue's description: > Consolidate SK_CRASH and sk_throw into SK_ABORT > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1610823002 > > Committed: https://skia.googlesource.com/skia/+/4c5cd7d527ed29aabfa72aa47b23a4496eeda357 TBR=reed@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1620333002
* Consolidate SK_CRASH and sk_throw into SK_ABORTGravatar djsollen2016-01-22
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1610823002 Review URL: https://codereview.chromium.org/1610823002
* Clean up SkXfermode_opts.hGravatar mtklein2016-01-08
| | | | | | | | | | | | | | | | | | | | | | | | | It seems that MSVC + __vectorcall don't play well together, so back ourselves out into a situation where we don't need it. - Inline transfermode functions. This removes the need for SK_VECTORCALL. - Remove 565 destination specializations. Blending into 565 is not speed-critical enough to merit the code bloat. - Removing 565 specializations means a bunch of Sk4px code is now dead. 8888 xfermodes generally speed up a bit from inlining, smoothly ranging from no change down to 0.65x for the fastest functions like Plus or Modulate. 565 xfermodes generally slow down because we're doing 565 -> 8888 and 8888->565 conversion serially[1] and using the stack, smoothly ranging from no change up to 2x slower for the fastest functions like Plus and Modulate. [1] the 565->8888 conversion is actually being autovectorized BUG=skia:4765,skia:4776 GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1565223002 CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot No public API changes. TBR=reed@google.com Review URL: https://codereview.chromium.org/1565223002
* Fix GOOGLE3 Android build.Gravatar benjaminwagner2015-11-18
| | | | | | | | | | | DebugWriteToStderr isn't defined for Android. I'm not sure if I just didn't test compiling for Android or if this is due to a change in the base library. BUG=skia: No public API changes. TBR=reed@google.com Review URL: https://codereview.chromium.org/1438773003
* __vectorcall needs SSEGravatar mtklein2015-11-16
| | | | | | | | | | | We don't have builders in this mode, but Mozilla does. BUG=skia:4563 TBR=reed@google.com No public API changes. Review URL: https://codereview.chromium.org/1445283002
* For BUILD.public, let SkPreConfig.h set SK_RELEASE based on NDEBUG.Gravatar benjaminwagner2015-10-29
| | | | | | | | | | | | | | | | | Use DumpStackTrace in SkASSERT in GOOGLE3. There are extra assertions enabled in debug mode that cause RecordDraw_TextBounds to fail. New include causes a naming conflict with global name "base". Corresponding internal cl/106495354 No public API changes. TBR=reed@google.com BUG=skia: Review URL: https://codereview.chromium.org/1423013004
* move reinterpret_cast into SK_PREFETCHGravatar mtklein2015-10-28
| | | | | | | | | no public API changes TBR=reed@google.com BUG=skia: Review URL: https://codereview.chromium.org/1419573011
* Make SK_PREFETCH work on Windows too.Gravatar mtklein2015-10-27
| | | | | | | | | | | | - Use _mm_prefetch() if available, e.g. with MSVC. - Some other tidying up. No public API changes. TBR=reed@google.com BUG=skia: Review URL: https://codereview.chromium.org/1427663002
* Remove SkNEW and SkDELETE macrosGravatar mdempsky2015-09-22
| | | | | | | | | | | | | | | This CL removes the uses of SkNEW that have resprouted since commit 385fe4d, and removes the macros entirely now that Android and Chromium have been cleaned up to no longer depend on them. A bunch of files implicitly depend on #include <new> from SkPostConfig.h still though, so keep that for now. To be fixed in a followup CL. [mtklein mucking around] Only public API removed. TBR=reed@google.com Review URL: https://codereview.chromium.org/1360653004
* Move SkTemplates.h to private.Gravatar bungeman2015-08-19
| | | | | | | | SkTemplates.h contains a number of Skia specific utilities which are not designed for external use. In addition to reducing the external support burden, this will allow Skia to freely refactor this file. Review URL: https://codereview.chromium.org/1272293004
* IWYU: 'core' target, files starting A-C.Gravatar bungeman2015-08-05
| | | | | | | | | TBR=reed@google.com Verbal lgtm, does not change API. Committed: https://skia.googlesource.com/skia/+/7403d87db8e43d4c2b5b25ac22a0ebc22bd09d69 Review URL: https://codereview.chromium.org/1265033002
* Revert of IWYU: 'core' target, files starting A-C. (patchset #5 id:80001 of ↵Gravatar reed2015-08-04
| | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1265033002/ ) Reason for revert: revert to unblock DEPS roll ../../chrome/browser/chromeos/display/overscan_calibrator.cc:43:10: error: variable has incomplete type 'SkPath' SkPath base_path; Original issue's description: > IWYU: 'core' target, files starting A-C. > > TBR=reed@google.com > Verbal lgtm, does not change API. > > Committed: https://skia.googlesource.com/skia/+/7403d87db8e43d4c2b5b25ac22a0ebc22bd09d69 TBR=reed@google.com,mtklein@google.com,bungeman@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1273613002
* IWYU: 'core' target, files starting A-C.Gravatar bungeman2015-08-04
| | | | | | | TBR=reed@google.com Verbal lgtm, does not change API. Review URL: https://codereview.chromium.org/1265033002
* Clean up a few includes, introduce iwyu.Gravatar bungeman2015-07-29
| | | | | | | | | The current include-what-you-use with current clang is much less noisy and more useful than it has been in the past. This change introduces a few IWYU directives (which are helpful documentation for humans as well) and fixes a few sets of includes. Review URL: https://codereview.chromium.org/1207893002
* De-templatize Sk4pxXfermode code a bit.Gravatar mtklein2015-07-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This deduplicates a few pieces of code: - we end up with one copy of each xfer32() driver loop instead of one per xfermode; - we end up with two* copies of each xfermode implementation instead of ten**. * For a given Mode: Mode() itself and xfer_aa<Mode>(). ** From unrolling: twice at a stride of 8, once at 4, once at 2, and once at 1, then all again for when we have AA. This decreases the size of SkXfermode.o from 1.5M to 620K on x86-64 and from 1.3M to 680K on ARMv7+NEON. If we wanted to, we could eliminate the xfer_aa<Mode>() copy by tagging each Mode() function as __attribute__((noinline)) or its equivalent. This would result in another ~100K space savings. Performance is affected in proportion to the original xfermode speed: fast modes like Plus take the largest proportional hit, and slow modes like HardLight or SoftLight see essentially no hit at all. This adds SK_VECTORCALL to help keep this code fast on ARMv7 and Windows. I've looked at the ARMv7 generated code... it looks good, even pretty. For compatibility with SK_VECTORCALL, we now pass the vector-sized arguments by value instead of by reference. Some refactoring now allows us to declare each mode as just a static function instead of a struct, which simplifies things. TBR=reed@google.com No public API changes. BUG=skia: Committed: https://skia.googlesource.com/skia/+/e617e1525916d7ee684142728c0905828caf49da CQ_EXTRA_TRYBOTS=client.skia.compile:Build-Ubuntu-GCC-Arm7-Debug-Android_NoNeon-Trybot Review URL: https://codereview.chromium.org/1242743004
* Revert of De-templatize Sk4pxXfermode code a bit. (patchset #2 id:20001 of ↵Gravatar mtklein2015-07-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1242743004/) Reason for revert: http://build.chromium.org/p/client.skia.compile/builders/Build-Ubuntu-GCC-Arm7-Debug-Android_NoNeon/builds/1168/steps/build%20most/logs/stdio Original issue's description: > De-templatize Sk4pxXfermode code a bit. > > This deduplicates a few pieces of code: > - we end up with one copy of each xfer32() driver loop instead of one per xfermode; > - we end up with two* copies of each xfermode implementation instead of ten**. > > * For a given Mode: Mode() itself and xfer_aa<Mode>(). > ** From unrolling: twice at a stride of 8, once at 4, once at 2, and once at 1, then all again for when we have AA. > > This decreases the size of SkXfermode.o from 1.5M to 620K on x86-64 and from 1.3M to 680K on ARMv7+NEON. > > If we wanted to, we could eliminate the xfer_aa<Mode>() copy by tagging each Mode() function as __attribute__((noinline)) or its equivalent. This would result in another ~100K space savings. > > Performance is affected in proportion to the original xfermode speed: > fast modes like Plus take the largest proportional hit, and slow modes > like HardLight or SoftLight see essentially no hit at all. > > This adds SK_VECTORCALL to help keep this code fast on ARMv7 and Windows. I've looked at the ARMv7 generated code... it looks good, even pretty. > > For compatibility with SK_VECTORCALL, we now pass the vector-sized arguments by value instead of by reference. Some refactoring now allows us to declare each mode as just a static function instead of a struct, which simplifies things. > > TBR=reed@google.com > No public API changes. > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/e617e1525916d7ee684142728c0905828caf49da TBR=msarett@google.com,mtklein@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1245273005
* De-templatize Sk4pxXfermode code a bit.Gravatar mtklein2015-07-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This deduplicates a few pieces of code: - we end up with one copy of each xfer32() driver loop instead of one per xfermode; - we end up with two* copies of each xfermode implementation instead of ten**. * For a given Mode: Mode() itself and xfer_aa<Mode>(). ** From unrolling: twice at a stride of 8, once at 4, once at 2, and once at 1, then all again for when we have AA. This decreases the size of SkXfermode.o from 1.5M to 620K on x86-64 and from 1.3M to 680K on ARMv7+NEON. If we wanted to, we could eliminate the xfer_aa<Mode>() copy by tagging each Mode() function as __attribute__((noinline)) or its equivalent. This would result in another ~100K space savings. Performance is affected in proportion to the original xfermode speed: fast modes like Plus take the largest proportional hit, and slow modes like HardLight or SoftLight see essentially no hit at all. This adds SK_VECTORCALL to help keep this code fast on ARMv7 and Windows. I've looked at the ARMv7 generated code... it looks good, even pretty. For compatibility with SK_VECTORCALL, we now pass the vector-sized arguments by value instead of by reference. Some refactoring now allows us to declare each mode as just a static function instead of a struct, which simplifies things. TBR=reed@google.com No public API changes. BUG=skia: Review URL: https://codereview.chromium.org/1242743004
* remove SkInstCntGravatar mtklein2015-06-26
| | | | | | | | | | | | | | It's been outclassed by Valgrind and leak sanitizer, and it seems to be causing problems for external folks building Skia. I'm not sure why our own builds seem unaffected. Latest thread: https://groups.google.com/forum/#!topic/skia-discuss/oj9FsQwwSF0 BUG=skia: Review URL: https://codereview.chromium.org/1217573002
* Use SkMScalar as float by default to match Chromium.Gravatar mtklein2015-06-09
| | | | | | | | | | Tweak some test values to pass with floats. As expected, this regresses matrix44_setconcat_general by about 2x. BUG=skia: Review URL: https://codereview.chromium.org/1169813006
* Initial CL to create GrBatchTest infrastructureGravatar joshualitt2015-04-29
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1109153004
* Remove all code related to NaClGravatar borenet2015-04-02
| | | | | | | BUG=skia:3600 DOCS_PREVIEW= https://skia.org/?cl=1036283002 Review URL: https://codereview.chromium.org/1036283002
* C++11 override should now be supported by all of {bots,Chrome,Android,Mozilla}Gravatar mtklein2015-03-25
| | | | | | | | | NOPRESUBMIT=true BUG=skia: DOCS_PREVIEW= https://skia.org/?cl=1037793002 Review URL: https://codereview.chromium.org/1037793002
* Remove SkLONGLONG.Gravatar bungeman2015-03-17
| | | | | | | | | All users now define SkLONGLONG. This fixes a long outstanding TODO now that int64_t is required. BUG=skia:179 Review URL: https://codereview.chromium.org/1000933003