bungeman [Mon, 26 Jan 2015 22:32:09 +0000 (14:32 -0800)]
Revert of SSE4 opaque blend using intrinsics instead of assembly. (patchset #14 id:260001 of https://codereview.chromium.org/
874863002/)
Reason for revert:
This kills Mac 10.6 bots.
FAILED: c++ -MMD -MF obj/src/opts/opts_sse4.SkBlitRow_opts_SSE4.o.d -DSK_INTERNAL -DSK_GAMMA_SRGB -DSK_GAMMA_APPLY_TO_A8 -DSK_SCALAR_TO_FLOAT_EXCLUDED -DSK_ALLOW_STATIC_GLOBAL_INITIALIZERS=1 -DSK_SUPPORT_GPU=1 -DSK_SUPPORT_OPENCL=0 -DSK_FORCE_DISTANCE_FIELD_TEXT=0 -DSK_BUILD_FOR_MAC -DSK_CRASH_HANDLER -DSK_DEVELOPER=1 -I../../src/core -I../../src/utils -I../../include/c -I../../include/config -I../../include/core -I../../include/pathops -I../../include/pipe -I../../include/utils/mac -I../../include/effects -O0 -gdwarf-2 -mmacosx-version-min=10.6 -arch x86_64 -mssse3 -Wall -Wextra -Winit-self -Wpointer-arith -Wsign-compare -Wno-unused-parameter -Wno-invalid-offsetof -msse4.1 -c ../../src/opts/SkBlitRow_opts_SSE4.cpp -o obj/src/opts/opts_sse4.SkBlitRow_opts_SSE4.o
../../src/opts/SkBlitRow_opts_SSE4.cpp:15:27: warning: x86intrin.h: No such file or directory
../../src/opts/SkBlitRow_opts_SSE4.cpp: In function 'void S32A_Opaque_BlitRow32_SSE4(SkPMColor*, const SkPMColor*, int, U8CPU)':
../../src/opts/SkBlitRow_opts_SSE4.cpp:40: error: '_mm_testz_si128' was not declared in this scope
../../src/opts/SkBlitRow_opts_SSE4.cpp:45: error: '_mm_testc_si128' was not declared in this scope
Original issue's description:
> SSE4 opaque blend using intrinsics instead of assembly.
>
> Since we had such a hard time with the assembly versions of this blit (to the
> point that we have them completely disabled everywhere), I thought I'd take
> a shot at writing a version of the blit using intrinsics.
>
> The key feature of SSE4 we're exploiting is that we can use ptest (_mm_test*)
> to skip the blend when the 16 src pixels we consider each loop are all opaque
> or all transparent. _mm_shuffle_epi8 from SSSE3 also lends a hand to extract
> all those alphas.
>
> It's worth looking to see if we can backport this type of logic to SSE2 using
> _mm_movemask_epi8, or up to 32 pixels at a time using AVX.
>
> My local performance testing doesn't show this to be an unambiguous win
> (there are probably microbenchmarks and SKPs where we'd be better off just
> powering through the blend rather than looking at alphas), but the potential
> does seem tantalizing enough to let skiaperf vet it on the bots. (< 1.0x is a win.)
>
> DM says it draws pixel perfect compare to the old code.
>
> Microbenchmarks:
> bitmap_RGBA_8888_A_source_stripes_two 14us -> 14.4us 1.03x
> bitmap_RGBA_8888_A_source_stripes_three 14.3us -> 14.5us 1.01x
> bitmap_RGBA_8888_scale_bilerp 61.9us -> 62.2us 1.01x
> bitmap_RGBA_8888_update_volatile_scale_rotate_bilerp 102us -> 101us 0.99x
> bitmap_RGBA_8888_scale_rotate_bilerp 103us -> 101us 0.99x
> bitmap_RGBA_8888_scale 18.4us -> 18.2us 0.99x
> bitmap_RGBA_8888_A_scale_rotate_bicubic 71us -> 70us 0.99x
> bitmap_RGBA_8888_update_scale_rotate_bilerp 103us -> 101us 0.99x
> bitmap_RGBA_8888_A_scale_rotate_bilerp 112us -> 109us 0.98x
> bitmap_RGBA_8888_update_volatile 5.72us -> 5.58us 0.98x
> bitmap_RGBA_8888 5.73us -> 5.58us 0.97x
> bitmap_RGBA_8888_update 5.78us -> 5.6us 0.97x
> bitmap_RGBA_8888_A_scale_bilerp 70.7us -> 68us 0.96x
> bitmap_RGBA_8888_A_scale_bicubic 23.7us -> 21.8us 0.92x
> bitmap_RGBA_8888_A 13.9us -> 10.9us 0.78x
> bitmap_RGBA_8888_A_source_opaque 14us -> 6.29us 0.45x
> bitmap_RGBA_8888_A_source_transparent 14us -> 3.65us 0.26x
>
> Running over our ~70 SKP web page captures, this looks like we spend 0.7x
> the time in S32A_Opaque_BlitRow compared to the SSE2 version, which should
> be a decent predictor of real-world impact.
>
> BUG=chromium:399842
>
> Committed: https://skia.googlesource.com/skia/+/
04bc91b972417038fecfa87c484771eac2b9b785
TBR=henrik.smiding@intel.com,mtklein@google.com,herb@google.com,reed@google.com,thakis@chromium.org,mtklein@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:399842
Review URL: https://codereview.chromium.org/
874033004
bungeman [Mon, 26 Jan 2015 22:08:52 +0000 (14:08 -0800)]
Add sbix font to coloremoji gm.
Review URL: https://codereview.chromium.org/
797043002
mtklein [Mon, 26 Jan 2015 22:06:42 +0000 (14:06 -0800)]
SSE4 opaque blend using intrinsics instead of assembly.
Since we had such a hard time with the assembly versions of this blit (to the
point that we have them completely disabled everywhere), I thought I'd take
a shot at writing a version of the blit using intrinsics.
The key feature of SSE4 we're exploiting is that we can use ptest (_mm_test*)
to skip the blend when the 16 src pixels we consider each loop are all opaque
or all transparent. _mm_shuffle_epi8 from SSSE3 also lends a hand to extract
all those alphas.
It's worth looking to see if we can backport this type of logic to SSE2 using
_mm_movemask_epi8, or up to 32 pixels at a time using AVX.
My local performance testing doesn't show this to be an unambiguous win
(there are probably microbenchmarks and SKPs where we'd be better off just
powering through the blend rather than looking at alphas), but the potential
does seem tantalizing enough to let skiaperf vet it on the bots. (< 1.0x is a win.)
DM says it draws pixel perfect compare to the old code.
Microbenchmarks:
bitmap_RGBA_8888_A_source_stripes_two 14us -> 14.4us 1.03x
bitmap_RGBA_8888_A_source_stripes_three 14.3us -> 14.5us 1.01x
bitmap_RGBA_8888_scale_bilerp 61.9us -> 62.2us 1.01x
bitmap_RGBA_8888_update_volatile_scale_rotate_bilerp 102us -> 101us 0.99x
bitmap_RGBA_8888_scale_rotate_bilerp 103us -> 101us 0.99x
bitmap_RGBA_8888_scale 18.4us -> 18.2us 0.99x
bitmap_RGBA_8888_A_scale_rotate_bicubic 71us -> 70us 0.99x
bitmap_RGBA_8888_update_scale_rotate_bilerp 103us -> 101us 0.99x
bitmap_RGBA_8888_A_scale_rotate_bilerp 112us -> 109us 0.98x
bitmap_RGBA_8888_update_volatile 5.72us -> 5.58us 0.98x
bitmap_RGBA_8888 5.73us -> 5.58us 0.97x
bitmap_RGBA_8888_update 5.78us -> 5.6us 0.97x
bitmap_RGBA_8888_A_scale_bilerp 70.7us -> 68us 0.96x
bitmap_RGBA_8888_A_scale_bicubic 23.7us -> 21.8us 0.92x
bitmap_RGBA_8888_A 13.9us -> 10.9us 0.78x
bitmap_RGBA_8888_A_source_opaque 14us -> 6.29us 0.45x
bitmap_RGBA_8888_A_source_transparent 14us -> 3.65us 0.26x
Running over our ~70 SKP web page captures, this looks like we spend 0.7x
the time in S32A_Opaque_BlitRow compared to the SSE2 version, which should
be a decent predictor of real-world impact.
BUG=chromium:399842
Review URL: https://codereview.chromium.org/
874863002
halcanary [Mon, 26 Jan 2015 21:46:41 +0000 (13:46 -0800)]
site/dev/contrib/directory <= https://status.skia.org/
NOTRY=true
Review URL: https://codereview.chromium.org/
876873002
joshualitt [Mon, 26 Jan 2015 21:30:10 +0000 (13:30 -0800)]
GrBatchPrototype
BUG=skia:
Review URL: https://codereview.chromium.org/
845103005
derekf [Mon, 26 Jan 2015 20:59:06 +0000 (12:59 -0800)]
Remove clear function from SkGPipe
Clear no longer exists. (It's now a drawPaint call)
Review URL: https://codereview.chromium.org/
881563002
halcanary [Mon, 26 Jan 2015 20:49:00 +0000 (12:49 -0800)]
s/sk_tools::DrawCheckerboard/sk_tool_utils::draw_checkerboard/
BUG=skia:
Review URL: https://codereview.chromium.org/
873333004
halcanary [Mon, 26 Jan 2015 20:38:59 +0000 (12:38 -0800)]
site/dev/contrib/revert formatting and details
NOTRY=true
Review URL: https://codereview.chromium.org/
873483004
reed [Mon, 26 Jan 2015 20:28:54 +0000 (12:28 -0800)]
add bench for building mipmaps
BUG=skia:
TBR=
Review URL: https://codereview.chromium.org/
873293003
cwallez [Mon, 26 Jan 2015 20:20:14 +0000 (12:20 -0800)]
Fix Morphology effects sourcing outside of the crop rect.
BUG=skia:1766
Committed: https://skia.googlesource.com/skia/+/
f6be925b5615f07039ce95c3433039694a8d1679
Review URL: https://codereview.chromium.org/
781153002
bsalomon [Mon, 26 Jan 2015 19:46:52 +0000 (11:46 -0800)]
discard scratch render targets when they are recycled.
Review URL: https://codereview.chromium.org/
871373007
robertphillips [Mon, 26 Jan 2015 19:29:36 +0000 (11:29 -0800)]
Alter gpu veto
This CL unifies the treatment of the dashed and concave paths.
Before:
TP 28 FP 15 TN 8 FN 3 IND 3
After:
TP 28 FP 18 TN 7 FN 2 IND 2
One of the TrueNegatives that became a FalsePositive was the motivation use case (the Chromium busy spinner).
Committed: https://skia.googlesource.com/skia/+/
87a6a8e18c7d5bbc94f478b44c53dc0e0549f927
Review URL: https://codereview.chromium.org/
875913002
reed [Mon, 26 Jan 2015 19:24:37 +0000 (11:24 -0800)]
check effective cache-size for fixed-budget caches
BUG=skia:
Review URL: https://codereview.chromium.org/
876743002
halcanary [Mon, 26 Jan 2015 19:24:32 +0000 (11:24 -0800)]
Factor out checkerboard function in gm and sampleapp into tools.
Review URL: https://codereview.chromium.org/
834303005
halcanary [Mon, 26 Jan 2015 19:19:22 +0000 (11:19 -0800)]
prettify site/user/sample/hello
NOTRY=true
TBR=jcgregorio@google.com
Review URL: https://codereview.chromium.org/
874303002
bsalomon [Mon, 26 Jan 2015 19:19:16 +0000 (11:19 -0800)]
Stop incorrectly setting the clip bit in GrCMM
Review URL: https://codereview.chromium.org/
866403005
cwallez [Mon, 26 Jan 2015 15:45:53 +0000 (07:45 -0800)]
Collapse consecutive SkTableColorFilters
BUG=skia:1366
For the added bench, the collapsing makes the bench take:
- 70% of the time for CPU rendering of 3 consecutive matrix filters
- almost no change in the GPU rendering of the matrix filters
- 50% of the time for CPU and GPU rendering of 3 consecutive table filters
Review URL: https://codereview.chromium.org/
776673002
halcanary [Mon, 26 Jan 2015 15:45:47 +0000 (07:45 -0800)]
prettify site/dev/design/pdftheory
NOTRY=true
TBR=jcgregorio@google.com
Review URL: https://codereview.chromium.org/
868473006
jcgregorio [Mon, 26 Jan 2015 15:24:02 +0000 (07:24 -0800)]
Add docs on how to get a preview of markdown pages.
BUG=skia:
Review URL: https://codereview.chromium.org/
878593002
halcanary [Mon, 26 Jan 2015 15:19:07 +0000 (07:19 -0800)]
https://fiddle.skia.org/
NOTRY=true
Review URL: https://codereview.chromium.org/
868473005
mtklein [Mon, 26 Jan 2015 15:07:03 +0000 (07:07 -0800)]
Don't do a pointless << 0.
It's very common (universal?) that alpha is the top byte.
You'd hope the compiler would remove the left shift then,
but I've seen Clang just do a dumb left shift of zero. :(
BUG=skia:
Review URL: https://codereview.chromium.org/
872243003
robertphillips [Mon, 26 Jan 2015 15:05:04 +0000 (07:05 -0800)]
Revert of Alter gpu veto (patchset #1 id:1 of https://codereview.chromium.org/
875913002/)
Reason for revert:
Failing tests
Original issue's description:
> Alter gpu veto
>
> This CL unifies the treatment of the dashed and concave paths.
>
> Before:
> TP 28 FP 15 TN 8 FN 3 IND 3
>
> After:
> TP 28 FP 18 TN 7 FN 2 IND 2
>
> One of the TrueNegatives that became a FalsePositive was the motivation use case (the Chromium busy spinner).
>
> Committed: https://skia.googlesource.com/skia/+/
87a6a8e18c7d5bbc94f478b44c53dc0e0549f927
TBR=egdaniel@google.com,bsalomon@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/
879483003
robertphillips [Mon, 26 Jan 2015 15:00:04 +0000 (07:00 -0800)]
Fix Chrome build
Switch SkShader's toString method to not be pure virtual due to derived classes in Chromium
TBR=bsalomon@google.com
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/
875043002
robertphillips [Mon, 26 Jan 2015 14:53:05 +0000 (06:53 -0800)]
Alter gpu veto
This CL unifies the treatment of the dashed and concave paths.
Before:
TP 28 FP 15 TN 8 FN 3 IND 3
After:
TP 28 FP 18 TN 7 FN 2 IND 2
One of the TrueNegatives that became a FalsePositive was the motivation use case (the Chromium busy spinner).
Review URL: https://codereview.chromium.org/
875913002
tfarina [Mon, 26 Jan 2015 14:47:55 +0000 (06:47 -0800)]
Update references to skiaperf.com.
The new server is being run in perf.skia.org.
BUG=None
R=jcgregorio@google.com
Review URL: https://codereview.chromium.org/
866943003
robertphillips [Mon, 26 Jan 2015 14:08:52 +0000 (06:08 -0800)]
Add patheffects to debugger printout
TBR=bsalomon@google.com
Review URL: https://codereview.chromium.org/
872043002
robertphillips [Mon, 26 Jan 2015 13:39:26 +0000 (05:39 -0800)]
Fix Windows build
TBR=jvanverth@google.com
NOTRY=true
NOTREECHECKS=true
Review URL: https://codereview.chromium.org/
876643002
kkinnunen [Mon, 26 Jan 2015 08:14:26 +0000 (00:14 -0800)]
Fold alpha to the inner savelayer in savelayer-savelayer-restore patterns
Fold alpha to the inner savelayer in savelayer-savelayer-restore
patterns such as this:
SaveLayer (non-opaque)
Save
ClipRect
SaveLayer
Restore
Restore
Restore
Current blink generates these for example for SVG content such as this:
<path style="opacity:0.5 filter:url(#blur_filter)"/>
The outer save layer is due to the opacity and the inner one is due to
blur filter being implemented with picture image filter.
Reduces layers in desk_carsvg.skp testcase from 115 to 78.
BUG=skia:3119
Review URL: https://codereview.chromium.org/
835973005
skia.buildbots [Mon, 26 Jan 2015 06:29:44 +0000 (22:29 -0800)]
Update SKP version
Automatic commit by the RecreateSKPs bot.
TBR=
Review URL: https://codereview.chromium.org/
873163002
reed [Sun, 25 Jan 2015 18:33:58 +0000 (10:33 -0800)]
initial preroll api
BUG=skia:
Review URL: https://codereview.chromium.org/
855473002
skia.buildbots [Sun, 25 Jan 2015 06:26:51 +0000 (22:26 -0800)]
Update SKP version
Automatic commit by the RecreateSKPs bot.
TBR=
Review URL: https://codereview.chromium.org/
870353002
halcanary [Sat, 24 Jan 2015 21:04:57 +0000 (13:04 -0800)]
experimental/skp_to_pdf_md5 optionally also outputs pdf files
TBR=mtklein@google.com
Review URL: https://codereview.chromium.org/
868333002
mtklein [Sat, 24 Jan 2015 19:27:27 +0000 (11:27 -0800)]
Don't leak image in Surface test.
==7023== 5,056 (896 direct, 4,160 indirect) bytes in 8 blocks are definitely lost in loss record 947 of 2,656
==7023== at 0x4C2B1C7: operator new(unsigned long) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==7023== by 0x82CB99: SkNewImageFromBitmapTexture(SkBitmap const&, int, SkSurface::Budgeted) (SkImage_Gpu.cpp:64)
==7023== by 0x81A1CF: SkSurface_Gpu::onNewImageSnapshot(SkSurface::Budgeted) (SkSurface_Gpu.cpp:50)
==7023== by 0x694F9D: SkSurface::newImageSnapshot(SkSurface::Budgeted) (SkSurface_Base.h:92)
==7023== by 0x55EA7C: test_Surface(skiatest::Reporter*, GrContextFactory*) (SurfaceTest.cpp:485)
==7023== by 0x407CB2: run_test(skiatest::Test*) (DM.cpp:399)
==7023== by 0x408382: run_enclave_and_gpu_tests(SkTArray<Task, false>*) (DM.cpp:411)
==7023== by 0x68B71E: SkTaskGroup::wait() (SkTaskGroup.cpp:67)
==7023== by 0x40934E: dm_main() (DM.cpp:455)
==7023== by 0x409483: main (DM.cpp:477)
http://build.chromium.org/p/client.skia/builders/Test-Ubuntu12-ShuttleA-GTX550Ti-x86_64-Release-Valgrind/builds/276/steps/dm/logs/stdio
TBR=bsalomon@google.com
BUG=skia:
Review URL: https://codereview.chromium.org/
872183002
skia.buildbots [Sat, 24 Jan 2015 07:00:15 +0000 (23:00 -0800)]
Update SKP version
Automatic commit by the RecreateSKPs bot.
TBR=
Review URL: https://codereview.chromium.org/
871143002
yunchao.he [Sat, 24 Jan 2015 01:06:20 +0000 (17:06 -0800)]
a typo in SkResourceCacheTest
BUG=skia:
Review URL: https://codereview.chromium.org/
868613002
mtklein [Sat, 24 Jan 2015 00:09:32 +0000 (16:09 -0800)]
Revert of Fix Morphology effects sourcing outside of the crop rect. (patchset #6 id:100001 of https://codereview.chromium.org/
781153002/)
Reason for revert:
Looks like this is causing memory leaks:
http://build.chromium.org/p/client.skia/builders/Test-Ubuntu13.10-GCE-NoGPU-x86_64-Debug-ASAN/builds/1155/steps/dm/logs/stdio
And causing crashes on Mac 10.6:
http://build.chromium.org/p/client.skia/builders/Test-Mac10.6-MacMini4.1-GeForce320M-x86_64-Debug/builds/1417/steps/dm/logs/stdio
Original issue's description:
> Fix Morphology effects sourcing outside of the crop rect.
>
> BUG=skia:1766
>
> Committed: https://skia.googlesource.com/skia/+/
f6be925b5615f07039ce95c3433039694a8d1679
TBR=junov@google.com,junov@chromium.org,bsalomon@google.com,reed@google.com,cwallez@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:1766
Review URL: https://codereview.chromium.org/
868973005
tfarina [Fri, 23 Jan 2015 22:48:53 +0000 (14:48 -0800)]
Cleanup: Delete buildbot_globals.py script.
rebaseline_server was the only user of this code but it was removed in
https://chromium.googlesource.com/skia/+/
3886046f008f0542de36cbeb35e220404e7c88a9
So there aren't more users of this script and we can remove it now.
BUG=skia:3200
R=borenet@google.com
Review URL: https://codereview.chromium.org/
873593005
cwallez [Fri, 23 Jan 2015 21:35:10 +0000 (13:35 -0800)]
Fix Morphology effects sourcing outside of the crop rect.
BUG=skia:1766
Review URL: https://codereview.chromium.org/
781153002
bsalomon [Fri, 23 Jan 2015 21:19:00 +0000 (13:19 -0800)]
Zap the scratch key on non-RT textures when scratch textures are disabled.
Review URL: https://codereview.chromium.org/
870103002
bsalomon [Fri, 23 Jan 2015 20:47:59 +0000 (12:47 -0800)]
Fix the speeling of "purgeable" in Gr code
TBR=robertphillips@google.com
Review URL: https://codereview.chromium.org/
874693002
halcanary [Fri, 23 Jan 2015 19:45:10 +0000 (11:45 -0800)]
Cleanup SkPDFObject::emit*
Review URL: https://codereview.chromium.org/
869783003
mtklein [Fri, 23 Jan 2015 19:07:07 +0000 (11:07 -0800)]
remove unused GM flags
Depends on https://codereview.chromium.org/
873753002/
Thumbs up to CLion for refactoring this for me.
BUG=skia:
Review URL: https://codereview.chromium.org/
867963004
bsalomon [Fri, 23 Jan 2015 19:02:50 +0000 (11:02 -0800)]
Remove deprecated SkSurface::NewRenderTarget factories
Review URL: https://codereview.chromium.org/
837723008
mtklein [Fri, 23 Jan 2015 18:39:55 +0000 (10:39 -0800)]
run clean branch baseline only once
BUG=skia:
Review URL: https://codereview.chromium.org/
874643002
mtklein [Fri, 23 Jan 2015 18:31:45 +0000 (10:31 -0800)]
Spin off GM::runAsBench() from flags.
This will let us kill flags.
BUG=skia:
Review URL: https://codereview.chromium.org/
873753002
fmalita [Fri, 23 Jan 2015 18:03:15 +0000 (10:03 -0800)]
Fix SampleApp picture-mode transform.
The multi-picture-draw path should not ignore the inherited transform.
R=reed@google.com,robertphillips@google.com
Review URL: https://codereview.chromium.org/
867303002
bsalomon [Fri, 23 Jan 2015 16:08:04 +0000 (08:08 -0800)]
Take budgeted param when snapping new image.
Review URL: https://codereview.chromium.org/
872543002
tfarina [Fri, 23 Jan 2015 16:06:13 +0000 (08:06 -0800)]
Fix 'Revert' instructions.
In the not so new pure Git world, 'svn fetch' and 'svn rebase' are not
needed anymore.
BUG=None
R=borenet@google.com
Review URL: https://codereview.chromium.org/
872433004
halcanary [Fri, 23 Jan 2015 15:52:58 +0000 (07:52 -0800)]
Collect everything Skia into one document.
http://skiadocs.com:8000/dev/contrib/directory?cl=
866133002
Review URL: https://codereview.chromium.org/
866133002
reed [Fri, 23 Jan 2015 15:51:14 +0000 (07:51 -0800)]
check for too-large rowBytes
BUG=446164
Review URL: https://codereview.chromium.org/
871993003
halcanary [Fri, 23 Jan 2015 15:47:55 +0000 (07:47 -0800)]
In Correctness Testing Doc, render --option correctly
TBR=mtklein@google.com
NOTRY=true
Review URL: https://codereview.chromium.org/
871993004
halcanary [Fri, 23 Jan 2015 15:22:58 +0000 (07:22 -0800)]
minor changes left out of crrev.com/
873543002
TBR=mtklein@google.com
Review URL: https://codereview.chromium.org/
872643005
bsalomon [Fri, 23 Jan 2015 15:19:22 +0000 (07:19 -0800)]
Allow unbudgeted resources to be recycled by the cache as scratch.
Review URL: https://codereview.chromium.org/
870743002
bsalomon [Fri, 23 Jan 2015 15:17:55 +0000 (07:17 -0800)]
Fix self assigment in GrResourceKey
TBR=robertphillips@google.com
BUG=skia:3340
Review URL: https://codereview.chromium.org/
866263007
mtklein [Fri, 23 Jan 2015 15:14:16 +0000 (07:14 -0800)]
Add a basic doc for correctness testing (DM).
https://skia.org/dev/contrib/testing?cl=
868983002
BUG=skia:
Review URL: https://codereview.chromium.org/
868983002
mtklein [Fri, 23 Jan 2015 15:01:26 +0000 (07:01 -0800)]
Update compiler warning flags
- add -Wsign-compare, which has been catching useful issues for Kimmo;
- add -Winit-self and -Wpointer-arith to Mac builds so everyone's using
the same flags;
- try try removing -Wno-uninitialized. This was only for the old 10.6
compiler that we have warnings set as non-errors now.
BUG=skia:
Review URL: https://codereview.chromium.org/
872793002
bsalomon [Fri, 23 Jan 2015 14:46:16 +0000 (06:46 -0800)]
Remove GrBinHashKey
Review URL: https://codereview.chromium.org/
861323002
kkinnunen [Fri, 23 Jan 2015 14:43:05 +0000 (06:43 -0800)]
Compile fix after Add specialized content key class for resources
gcc (Ubuntu/Linaro 4.6.4-1ubuntu1~12.04) 4.6.4
error: comparison between signed and unsigned integer expressions
Review URL: https://codereview.chromium.org/
871013002
halcanary [Fri, 23 Jan 2015 14:17:35 +0000 (06:17 -0800)]
More changes to SkPDFShader to eliminate multiple inheritance!
Review URL: https://codereview.chromium.org/
873543002
reed [Fri, 23 Jan 2015 13:58:07 +0000 (05:58 -0800)]
add newImage API
BUG=skia:3277
related bug: skbug.com/3276
Review URL: https://codereview.chromium.org/
821083002
mtklein [Fri, 23 Jan 2015 13:48:00 +0000 (05:48 -0800)]
Write dm.json periodically instead of only once at the end.
This way if a bot crashes, we might get some partial results in gold rather
than none. We do the same sort of thing in nanobench for perf.
BUG=skia:3255
Review URL: https://codereview.chromium.org/
872443003
mtklein [Fri, 23 Jan 2015 13:47:55 +0000 (05:47 -0800)]
minor readability / refactors
I have been hacking at this test trying to understand why the N5 is
still sometimes crashy (it seems, less but not zero now). No luck so far.
But, while I've been reading and hacking at it, I think I've made a
few small improvements, mostly to readability.
BUG=skia:
Review URL: https://codereview.chromium.org/
870803002
reed [Fri, 23 Jan 2015 12:24:16 +0000 (04:24 -0800)]
more reinforcement that images never have zero width or height
BUG=skia:
Review URL: https://codereview.chromium.org/
869743002
bsalomon [Fri, 23 Jan 2015 12:24:04 +0000 (04:24 -0800)]
Add specialized content key class for resources.
Review URL: https://codereview.chromium.org/
858123002
skia.buildbots [Fri, 23 Jan 2015 12:19:00 +0000 (04:19 -0800)]
Update SKP version
Automatic commit by the RecreateSKPs bot.
TBR=
Review URL: https://codereview.chromium.org/
866383002
halcanary [Fri, 23 Jan 2015 12:18:53 +0000 (04:18 -0800)]
Simplify SkPDFShader class. Now invalid objects are never created.
"Constructors should not do real work"
I have verified that all test PDFs render identically.
Review URL: https://codereview.chromium.org/
862113004
mtklein [Thu, 22 Jan 2015 21:50:35 +0000 (13:50 -0800)]
Move FP texture test buffers to heap.
This is a speculative fix for the crashing N5 bots. It looks like the bots are
always failing in or around FloatingPointTextureTest.
It looks like sometimes they're hitting a SIGBUS, which I suspect is stack
overflow. FloatingPointTextureTest allocates ~320K on the stack, which may
be too much. This CL moves those buffers to the heap. For consistency I did
the same with the half-float tests, though they're only using ~1/8th the stack.
It looks like sometimes the bots are failing to malloc. I don't understand that,
and this CL doesn't address that directly. But it's possible this is still a stack
overflow, just trashing RAM and causing arbitrary mayhem instead of a SIGBUS.
I have no idea why this is a problem only on the N5. I have been unable to
reproduce this locally, neither with a K N5 nor an L N5, but the bots are pretty
reliable.
NOTREECHECKS=true
BUG=skia:
Review URL: https://codereview.chromium.org/
871623002
reed [Thu, 22 Jan 2015 21:41:00 +0000 (13:41 -0800)]
remove unnecessary guard flags for android (for conics)
BUG=skia:
NOTREECHECKS=True
Review URL: https://codereview.chromium.org/
868783002
mtklein [Thu, 22 Jan 2015 18:43:34 +0000 (10:43 -0800)]
android_run_skia: dump logcat on failure
logcat -c clears the log before we run.
logcat -d dumps the log stdout and exits.
BUG=skia:
Review URL: https://codereview.chromium.org/
870643002
dongseong.hwang [Thu, 22 Jan 2015 18:40:20 +0000 (10:40 -0800)]
Initialize the pad memory in GrBufferAllocPool.
Msan bot detects Use-of-uninitialized-value on the pad.
BUG=445745
Review URL: https://codereview.chromium.org/
865913002
mtklein [Thu, 22 Jan 2015 18:32:25 +0000 (10:32 -0800)]
Put close_gif() in an anonymous namespace.
Not a big deal, but matches the intention of it being a file-scoped function
better. This mirrors a recent google3 change for clients who don't use C++11.
BUG=skia:
Review URL: https://codereview.chromium.org/
865243002
scroggo [Thu, 22 Jan 2015 18:27:25 +0000 (10:27 -0800)]
Muck with the right cinfo.
In SkImageDecoder_libjpeg, modify cinfo *after* destroying it and
creating a new one in its place.
Should fix build breakage.
Committed: https://skia.googlesource.com/skia/+/
3629865bac20ae8092177f519594f79f89d09fb0
Review URL: https://codereview.chromium.org/
858333002
egdaniel [Thu, 22 Jan 2015 18:16:09 +0000 (10:16 -0800)]
Rename GrOptDrawState to GrPipeline and GrDrawState to GrPipelineBuilder
BUG=skia:
Review URL: https://codereview.chromium.org/
858343002
reed [Thu, 22 Jan 2015 17:37:46 +0000 (09:37 -0800)]
remove more dead code
BUG=skia:
Review URL: https://codereview.chromium.org/
865873003
reed [Thu, 22 Jan 2015 17:03:25 +0000 (09:03 -0800)]
remove (unused) GatherPixelRefs
BUG=skia:
Review URL: https://codereview.chromium.org/
869463002
mtklein [Thu, 22 Jan 2015 15:59:52 +0000 (07:59 -0800)]
fLuminance is unsed unless SK_GAMMA_APPLY_TO_A8 is defined
BUG=skia:
Review URL: https://codereview.chromium.org/
865103002
bungeman [Thu, 22 Jan 2015 15:33:51 +0000 (07:33 -0800)]
Fix SkIStream nits.
Fix comment, constness of one field, and delete already checks for NULL.
TBR=reed@google.com
Trivial change to debatably public api.
Review URL: https://codereview.chromium.org/
868643003
joshualitt [Thu, 22 Jan 2015 15:11:44 +0000 (07:11 -0800)]
XPFactory lazily initializie in drawstate / GrPaint
BUG=skia:
Review URL: https://codereview.chromium.org/
866573002
egdaniel [Thu, 22 Jan 2015 14:52:29 +0000 (06:52 -0800)]
Remove the need for asCoeff in SkXfermode.
BUG=skia:
Review URL: https://codereview.chromium.org/
864833002
bungeman [Thu, 22 Jan 2015 14:08:31 +0000 (06:08 -0800)]
Remove staging SkStream::unref().
SkStream::unref() was added to ease transitioning off of SkStream
deriving from SkRefCnt. It is no longer needed, remove it.
TBR=reed@google.com
Review URL: https://codereview.chromium.org/
861413002
skia.buildbots [Thu, 22 Jan 2015 07:09:41 +0000 (23:09 -0800)]
Update SKP version
Automatic commit by the RecreateSKPs bot.
TBR=
Review URL: https://codereview.chromium.org/
807263005
mtklein [Thu, 22 Jan 2015 03:51:27 +0000 (19:51 -0800)]
Don't require -DSK_USE_POSIX_THREADS.
To compile SkCondVar, we already require either pthreads or Windows. This
simplifies that code to not need SK_USE_POSIX_THREADS to be explicitly defined.
We'll just look to see if we're targeting Windows, and if not, assume pthreads.
Both before and after this CL, that code will fail to compile if we're not on
Windows and don't have pthreads.
BUG=skia:
Review URL: https://codereview.chromium.org/
869443003
mtklein [Wed, 21 Jan 2015 23:50:13 +0000 (15:50 -0800)]
More natural way to serialize GPU tasks and tests.
This basically takes out the Windows-only hacks and promotes them to
cross-platform behavior driven by --gpu_threading.
- When --gpu_threading is false (the default), this puts GPU tasks and tests
together in the same GPU enclave. They all run serially.
- When --gpu_threading is true, both the tests and the tasks run totally
independently, just like the thread-safe CPU-bound work.
BUG=skia:3255
Review URL: https://codereview.chromium.org/
847273005
bungeman [Wed, 21 Jan 2015 23:08:10 +0000 (15:08 -0800)]
Revert of Muck with the right cinfo. (patchset #2 id:20001 of https://codereview.chromium.org/
858333002/)
Reason for revert:
Appears to cause Android dm to segfault.
Original issue's description:
> Muck with the right cinfo.
>
> In SkImageDecoder_libjpeg, modify cinfo *after* destroying it and
> creating a new one in its place.
>
> Should fix build breakage.
>
> Committed: https://skia.googlesource.com/skia/+/
3629865bac20ae8092177f519594f79f89d09fb0
TBR=scroggo@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/
858323003
scroggo [Wed, 21 Jan 2015 22:04:57 +0000 (14:04 -0800)]
Muck with the right cinfo.
In SkImageDecoder_libjpeg, modify cinfo *after* destroying it and
creating a new one in its place.
Should fix build breakage.
Review URL: https://codereview.chromium.org/
858333002
mtklein [Wed, 21 Jan 2015 21:48:57 +0000 (13:48 -0800)]
Easy DM TODO: LazyDecodeBitmap does not help (or hinder).
BUG=skia:3255
Review URL: https://codereview.chromium.org/
859303003
mtklein [Wed, 21 Jan 2015 21:18:51 +0000 (13:18 -0800)]
Don't test pipe modes nobody uses.
SkDeferredCanvas uses a simple pipe: no cross-process, no shared-address, etc.
(see src/utils/SkDeferredCanvas.cpp:306).
We could just remove these modes from the bot configs, but I'd like to take the
opportunity to simplify the DM code too. I'll happily volunteer to put things
back should we decide we want to test these modes.
BUG=skia:
Review URL: https://codereview.chromium.org/
861303003
mtklein [Wed, 21 Jan 2015 21:13:31 +0000 (13:13 -0800)]
Move sync code to include/, switch from using platform define to a proxy header in core/
This fixes two problems:
1) #include SK_SOME_DEFINE doesn't work well for all our clients.
2) Things in include/ are #including things in src/, which we don't like.
TBR=reed@google.com
BUG=skia:
Review URL: https://codereview.chromium.org/
862983002
halcanary [Wed, 21 Jan 2015 21:13:22 +0000 (13:13 -0800)]
Use SkLazyPtr in SkPDFGraphicState.cpp
Motivation: currently we rely on mutexes for guarding static
initialization. These mutexes will go away.
Review URL: https://codereview.chromium.org/
815223005
scroggo [Wed, 21 Jan 2015 20:33:29 +0000 (12:33 -0800)]
And change SkAutoTUnref<const SkStream to SkAutoTDelete.
Should have been included with https://codereview.chromium.org/
860353005/
TBR=bungeman@google.com
NOTRY=true
NOTREECHECKS=true
Review URL: https://codereview.chromium.org/
844193007
scroggo [Wed, 21 Jan 2015 20:23:20 +0000 (12:23 -0800)]
Remove another caller of SkRef(SkStream)
TBR=bungeman@google.com
NOTRY=true
NOTREECHECKS=true
Review URL: https://codereview.chromium.org/
860353005
djsollen [Wed, 21 Jan 2015 20:11:00 +0000 (12:11 -0800)]
Update the version of cpu-features that we use for testing.
Review URL: https://codereview.chromium.org/
858233003
scroggo [Wed, 21 Jan 2015 20:09:53 +0000 (12:09 -0800)]
Make SkStream *not* ref counted.
SkStream is a stateful object, so it does not make sense for it to have
multiple owners. Make SkStream inherit directly from SkNoncopyable.
Update methods which previously called SkStream::ref() (e.g.
SkImageDecoder::buildTileIndex() and SkFrontBufferedStream::Create(),
which required the existing owners to call SkStream::unref()) to take
ownership of their SkStream parameters and delete when done (including
on failure).
Switch all SkAutoTUnref<SkStream>s to SkAutoTDelete<SkStream>s. In some
cases this means heap allocating streams that were previously stack
allocated.
Respect ownership rules of SkTypeface::CreateFromStream() and
SkImageDecoder::buildTileIndex().
Update the comments for exceptional methods which do not affect the
ownership of their SkStream parameters (e.g.
SkPicture::CreateFromStream() and SkTypeface::Deserialize()) to be
explicit about ownership.
Remove test_stream_life, which tested that buildTileIndex() behaved
correctly when SkStream was a ref counted object. The test does not
make sense now that it is not.
In SkPDFStream, remove the SkMemoryStream member. Instead of using it,
create a new SkMemoryStream to pass to fDataStream (which is now an
SkAutoTDelete).
Make other pdf rasterizers behave like SkPDFDocumentToBitmap.
SkPDFDocumentToBitmap delete the SkStream, so do the same in the
following pdf rasterizers:
SkPopplerRasterizePDF
SkNativeRasterizePDF
SkNoRasterizePDF
Requires a change to Android, which currently treats SkStreams as ref
counted objects.
Review URL: https://codereview.chromium.org/
849103004
hcm [Wed, 21 Jan 2015 20:05:47 +0000 (12:05 -0800)]
Add Contributing to Skia section of docs
BUG=skia:
Review URL: https://codereview.chromium.org/
844433004
bungeman [Wed, 21 Jan 2015 19:55:16 +0000 (11:55 -0800)]
Lcd request early check in SkFontHost_FreeType::onFilterRec.
If the user didn't request lcd, don't spend any time checking if the
FT_Library supports it.
Review URL: https://codereview.chromium.org/
864903002
joshualitt [Wed, 21 Jan 2015 19:52:36 +0000 (11:52 -0800)]
remove drawtype
BUG=skia:
Review URL: https://codereview.chromium.org/
862933005
bungeman [Wed, 21 Jan 2015 19:19:22 +0000 (11:19 -0800)]
Reduce overhead of SkFontHost_FreeType::onFilterRec.
The current code is using AutoFTAccess just to access the FT_Library.
However, it does not need to resolve the FT_Face, just the FT_Library.
This unecessary overhead and is removed by this change.
The longer term solution is for SkFontMgr to initialize FreeType.
Review URL: https://codereview.chromium.org/
835583003
joshualitt [Wed, 21 Jan 2015 18:16:17 +0000 (10:16 -0800)]
remove drawType from optState
BUG=skia:
Review URL: https://codereview.chromium.org/
864853002
halcanary [Wed, 21 Jan 2015 17:59:14 +0000 (09:59 -0800)]
SkPDFCanon
SkPDFCanon's fields and methods will eventually become part of
SkPDFDocument/SkDocument_PDF. For now, it exists as a singleton to
preflight that transition. This replaces three global arrays in
SkPDFFont, SkPDFShader, and SkPDFGraphicsContext. This code is still
thread-unsafe (http://skbug.com/2683), but moving this functionality
into SkPDFDocument will fix that.
This CL does not change pdf output from either GMs or SKPs.
This change also simplifies some code around the SkPDFCanon methods.
BUG=skia:2683
Review URL: https://codereview.chromium.org/
842253003
bsalomon [Wed, 21 Jan 2015 17:32:40 +0000 (09:32 -0800)]
Reland https://codereview.chromium.org/
860333002 with fix for test failures.
Revert "Revert of Make GrScratchKey memory buffer correct size on copy (patchset #1 id:1 of https://codereview.chromium.org/
860333002/)"
This reverts commit
988018c817f341c0ce09297b7ba5ba60ba76eba9.
BUG=skia:
Review URL: https://codereview.chromium.org/
863983003