Commit Graph

45096 Commits

Author SHA1 Message Date
Michael Ludwig
ba97189a3c Skip unnecessary moveTo in degenerate quad calculations
Change-Id: If73951f8e183101b80f729d9533cc3c8395b1879
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252481
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2019-11-04 17:38:44 +00:00
Eric Boren
2697d14ac6 Reland "[recipes] Assert that Git is obtained from CIPD"
This reverts commit 491eba5f1d.

Reason for revert: Should be fixed

Original change's description:
> Revert "[recipes] Assert that Git is obtained from CIPD"
> 
> This reverts commit 6751f171c6.
> 
> Reason for revert: Missed at least one
> 
> Original change's description:
> > [recipes] Assert that Git is obtained from CIPD
> > 
> > Bug: skia:9538
> > Change-Id: I0e2bed991e099646c89fd87895851caf5d0734b8
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251658
> > Reviewed-by: Kevin Lubick <kjlubick@google.com>
> > Commit-Queue: Eric Boren <borenet@google.com>
> 
> TBR=borenet@google.com,kjlubick@google.com
> 
> Change-Id: Ic90ae5672ce605f1667d7f961026303905824032
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: skia:9538
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252190
> Reviewed-by: Eric Boren <borenet@google.com>
> Commit-Queue: Eric Boren <borenet@google.com>

TBR=borenet@google.com,kjlubick@google.com

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: skia:9538
Change-Id: I2dfbd66c75e6b41a5f63b3f89bf8988827a639d9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252480
Reviewed-by: Eric Boren <borenet@google.com>
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-11-04 16:40:29 +00:00
Peng Huang
3cfde4ef4d Make GrVkResource::Trace thread safe.
Bug: skia: None
Change-Id: I5fbbc9c885d8eb947682a043f66fd1ecf53a9ed6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250865
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2019-11-04 16:34:59 +00:00
Eric Boren
e99683ac6d [infra] Make SkottieWASM and LottieWeb use git from CIPD
Bug: skia:9588
Change-Id: Ie37eeae3a971d74edee50d87d96d452fad1b38a4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252476
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-11-04 16:05:06 +00:00
Brian Osman
e36d030016 SkColorMatrix cleanup
Remove the RGB/YUV helpers (use SkYUVMath instead), along with the
unused get20/set20.

Change-Id: Id83467a1b7f33657869e0a933af75387a4e36a88
Bug: skia:9543
Change-Id: Id83467a1b7f33657869e0a933af75387a4e36a88
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252188
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-11-04 15:20:15 +00:00
skia-autoroll
feac94f276 Roll third_party/externals/angle2 e96039218e9d..6c7208f93d6e (8 commits)
e96039218e..6c7208f93d

git log e96039218e9d..6c7208f93d6e --date=short --no-merges --format='%ad %ae %s'
2019-11-03 jmadill@chromium.org Capture/Replay: Implement mid-execution replay.
2019-11-03 jmadill@chromium.org Capture/Replay: Capture GetFloatv params.
2019-11-03 jmadill@chromium.org Capture/Replay: Only convert GLES 2 GLenums to string.
2019-11-02 jmadill@chromium.org Delete stale unused proc table functions.
2019-11-01 jmadill@chromium.org Fix ANGLE_get_image cube map handling.
2019-11-01 shrekshao@google.com Reorder BaseVertexBaseInstance draw calls parameters
2019-11-01 lehoangq@gmail.com Metal backend implementation pt 2
2019-11-01 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/glslang/src b131630e7c74..48233ad3d45b (1 commits)

Created with:
  gclient setdep -r third_party/externals/angle2@6c7208f93d6e

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-skia-autoroll
Please CC ethannicholas@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Bug: None
TBR=ethannicholas@google.com
Change-Id: I9076a21d3e2cbaf511be651b2bcac4a95fa70573
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252416
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-11-04 06:13:48 +00:00
skia-autoroll
42d236eaeb Roll third_party/externals/swiftshader fda994c63075..aaa64b76c0b4 (8 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/fda994c63075..aaa64b76c0b4

git log fda994c63075..aaa64b76c0b4 --date=short --no-merges --format='%ad %ae %s'
2019-11-01 amaiorano@google.com Modify Blitter to implement FunctionT
2019-11-01 amaiorano@google.com Modify SetupRoutine to implement FunctionT
2019-11-01 amaiorano@google.com Modify PixelRoutine to implement FunctionT
2019-11-01 amaiorano@google.com Modify VertexRoutine to implement FunctionT
2019-11-01 amaiorano@google.com ReactorUnitTests: use FunctionT
2019-11-01 amaiorano@google.com Reactor: add type-safe FunctionT and RoutineT
2019-11-01 natsu@google.com Allow concurrent eglSwapBuffers() with same display but different surfaces
2019-11-01 natsu@google.com Move egl locking code from main.cpp to libEGL.cpp

Created with:
  gclient setdep -r third_party/externals/swiftshader@aaa64b76c0b4

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/swiftshader-skia-autoroll
Please CC ethannicholas@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
TBR=ethannicholas@google.com
Change-Id: I2bd5fe12b73969fb59613e64a963f2ad18ca5c71
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252417
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-11-04 04:38:18 +00:00
skia-recreate-skps
4cc2dc64ff Update SKP version
Automatic commit by the RecreateSKPs bot.

TBR=rmistry@google.com
NO_MERGE_BUILDS

Change-Id: Ie683f87b64ffa456a8ec2f054e2f589d70f90359
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252376
Reviewed-by: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
Commit-Queue: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
2019-11-03 08:37:13 +00:00
Robert Phillips
8e083eee8e Tighten up min and max vertex indices passed to GrTextureOp's meshes
Change-Id: Ie06c763f8677c395fdc4995bf78b9aff95040764
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252192
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2019-11-01 21:46:51 +00:00
recipe-roller
ef7677fc60 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
recipe_engine:
  https://crrev.com/e9ca19a0946a226ba6011bfadcc19a13340268dd Improve docstrings for step module. (gbeaty@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I217ded339a9a04da4ab6cf5b0e0e33fddf645229
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252278
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-11-01 21:31:41 +00:00
Michael Ludwig
3699a177bb Progress towards consolidating aa mask and edge distances
Change-Id: I47bd68532a68b7464ef6ed43733fef3d65792cfb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251762
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-11-01 21:05:11 +00:00
Ethan Nicholas
8633e4f304 Revert "Implement sample mask and sample locations support in Vulkan"
This reverts commit 8b915a0c27.

Reason for revert: Vulkan bot failures

Original change's description:
> Implement sample mask and sample locations support in Vulkan
> 
> Change-Id: I372695ec5360def42a8a997675993264740b0da4
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252038
> Commit-Queue: Chris Dalton <csmartdalton@google.com>
> Reviewed-by: Chris Dalton <csmartdalton@google.com>

TBR=csmartdalton@google.com,ethannicholas@google.com

Change-Id: I53023102009985e1e883c2a6a6ec4bfb18baf897
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252259
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2019-11-01 20:52:15 +00:00
Ethan Nicholas
8b915a0c27 Implement sample mask and sample locations support in Vulkan
Change-Id: I372695ec5360def42a8a997675993264740b0da4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252038
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
2019-11-01 20:22:25 +00:00
Kevin Lubick
79b7134b5f [canvaskit] Add relative SkPath operators
Like with the non-relative forms, we want to be able to
chain these together, but not leak the SkPaths (which happens
if the C++ side returns this). Thus, we have to add in
the JS glue to return the "JS this".

Change-Id: Ic640b84f6c09c1d931ad44bc403b14bb0d0893a2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251960
Reviewed-by: Hal Canary <halcanary@google.com>
2019-11-01 20:08:27 +00:00
recipe-roller
5d5c9bf1d5 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
depot_tools:
  https://crrev.com/ab7bec3434965ccf4553663caa47540375f00abc Make find_owners_test.py pass consistently. (danakj@chromium.org)
  https://crrev.com/c39a77883d7b129f34610cfadd658b4b333d9458 [gclient] Reset to parent commit with rebase_patch_ref=False instead of master. (iannucci@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I86a94aa31e9689e7bcefe39482518df277a78e16
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252231
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-11-01 19:14:14 +00:00
Robert Phillips
e2e3a2fc57 Revert "Reduce max # of AA Quads that can be merged or chained into a single GrTextureOp"
This reverts commit 0a4681d044.

Reason for revert: Maybe the cause of red bots

Original change's description:
> Reduce max # of AA Quads that can be merged or chained into a single GrTextureOp
> 
> It is, arguably, not a good metric but the max number of AA Quads that are merged or chained together across all Skia's GMs and SKPs is 276.
> 
> This should also reduce the memory consumed from 245,760 bytes to 30,720 bytes.
> 
> Bug: b/143572065
> Change-Id: Ia70d3671fa33e0d84b38b4788e8c74ef98a9661e
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252176
> Reviewed-by: Michael Ludwig <michaelludwig@google.com>
> Commit-Queue: Robert Phillips <robertphillips@google.com>

TBR=robertphillips@google.com,michaelludwig@google.com

Change-Id: Id38a1242327b853b494631d9fbc6f6d3f15d5aec
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: b/143572065
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252193
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2019-11-01 19:08:26 +00:00
Eric Boren
491eba5f1d Revert "[recipes] Assert that Git is obtained from CIPD"
This reverts commit 6751f171c6.

Reason for revert: Missed at least one

Original change's description:
> [recipes] Assert that Git is obtained from CIPD
> 
> Bug: skia:9538
> Change-Id: I0e2bed991e099646c89fd87895851caf5d0734b8
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251658
> Reviewed-by: Kevin Lubick <kjlubick@google.com>
> Commit-Queue: Eric Boren <borenet@google.com>

TBR=borenet@google.com,kjlubick@google.com

Change-Id: Ic90ae5672ce605f1667d7f961026303905824032
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:9538
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252190
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-11-01 18:57:59 +00:00
Stephen White
183fc99ad8 Dawn: update to recent texture proxy changes.
Change-Id: I8f2b862d5631f4c9a2e2653ebd498f401ed1f949
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252185
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Stephen White <senorblanco@chromium.org>
2019-11-01 18:48:52 +00:00
Eric Boren
6751f171c6 [recipes] Assert that Git is obtained from CIPD
Bug: skia:9538
Change-Id: I0e2bed991e099646c89fd87895851caf5d0734b8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251658
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-11-01 18:47:08 +00:00
Eric Boren
0509373cd5 [infra] Make CheckGeneratedFiles use git from CIPD
Bug: skia:9588
Change-Id: Idb80f1714865c2aa81615b8fc26afd591c3f4b24
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252179
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-11-01 18:43:47 +00:00
Mike Klein
0393505a2d opaque shaders and srcover -> src
Program caching makes whether or not this is safe a little subtle.  It
is safe and I've tried to explain the subtlety in comments in the new
non-virtual Shader program() hook that forces all opaque shaders to
opaque, and in comments in SkVMBlitter where we make use of isOpaque().

I think this is the tidiest way to get the optimization and safety,
though it is a little awkward to have to write epic cross-referenced
comments explaining first why it might not generally be safe to use
shader->isOpaque() to make decisions in the blitter, and then how we
actually have made it really quite safe.

Many tiny partial-coverage diffs from how coverage interacts differently
with SrcOver and Src, SrcOver folding coverage into the src color before
blending with dst, Src just lerping with dst.

This all comes together really quite magically, changing a program to
draw a solid opaque color from this,

    11 registers, 41 instructions:
    r0 = uniform32 arg(0) 0
    r1 = splat FF (3.5733111e-43)
    r2 = extract r0 8 r1
    r3 = splat 80 (1.793662e-43)
    r4 = extract r0 24 r1
    r5 = sub_i32 r1 r4
    r6 = extract r0 16 r1
    r0 = extract r0 0 r1
    loop:
    r7 = load32 arg(1)
    r8 = extract r7 8 r1
    r8 = mul_i32 r8 r5
    r8 = add_i32 r8 r3
    r9 = shr_i32 r8 8
    r9 = add_i32 r8 r9
    r9 = shr_i32 r9 8
    r9 = add_i32 r2 r9
    r8 = extract r7 0 r1
    r8 = mul_i32 r8 r5
    r8 = add_i32 r8 r3
    r10 = shr_i32 r8 8
    r10 = add_i32 r8 r10
    r10 = shr_i32 r10 8
    r10 = add_i32 r6 r10
    r9 = pack r10 r9 8
    r10 = extract r7 16 r1
    r10 = mul_i32 r10 r5
    r10 = add_i32 r10 r3
    r8 = shr_i32 r10 8
    r8 = add_i32 r10 r8
    r8 = shr_i32 r8 8
    r8 = add_i32 r0 r8
    r7 = extract r7 24 r1
    r7 = mul_i32 r7 r5
    r7 = add_i32 r7 r3
    r10 = shr_i32 r7 8
    r10 = add_i32 r7 r10
    r10 = shr_i32 r10 8
    r10 = add_i32 r4 r10
    r10 = pack r8 r10 8
    r10 = pack r9 r10 16
    store32 arg(1) r10

to this,

    4 registers, 9 instructions:
    r0 = uniform32 arg(0) 0
    r1 = splat FF (3.5733111e-43)
    r2 = extract r0 8 r1
    r3 = extract r0 16 r1
    r2 = pack r3 r2 8
    r0 = extract r0 0 r1
    r1 = pack r0 r1 8
    r1 = pack r2 r1 16
    loop:
    store32 arg(1) r1

Change-Id: Ic1e2ac1496252970743ef44b17908965bc73e384
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252198
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-11-01 18:31:35 +00:00
Mike Klein
4483c22ead get rid of Uniforms
Now that we've turned paint colors into shaders where appropriate,
SkVMBlitter's Uniforms struct is only really holding one byte of
coverage for when we're in RLE coverage mode.

We can just pass that coverage as its own uniform pointer, much like we
pass a pointer for masks.  This means there's no need to think about the
(notional) Uniforms struct any more, and leaves the first, main uniform
parameter holding shader uniforms exclusively.

Change-Id: I1c45d8c3280816836b011e22e07a666952a9df63
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252080
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-11-01 18:19:05 +00:00
Michael Ludwig
e64c8bf477 Refactor tessellation metadata to move towards independent inset/outset calculations
Change-Id: Iaf1daad359cd7478ed42966bd65231ff108e602c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251661
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-11-01 18:16:35 +00:00
Mike Klein
9d0c67ab1b paint color -> shader
This means we can share programs with color shaders
whether they come through as a paint color or shader.

The GM now only ever JITs one program.

Change-Id: If61f9e7b79aa6b8fd1de7c16ff52f78bfd7dc4ec
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252079
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-11-01 17:57:15 +00:00
Mike Klein
476061e4ce paint alpha scaling as its own effect
I'd like to express each of the special automatic features of the color
pipeline as their own effects in SkVMBlitter where possible.  This turns
the modulate-shader-by-paint-alpha feature into an explicit shader
wrapper.

This also sort of shows off how program() and uniforms() can chain
together.  This is the same basic form that SkColorFilterShader will
take, since scaling by alpha is basically a color filter.  (And indeed,
I may follow up by reformulating this as AlphaColorFilter once I get
color filters and SkColorFilterShader working with SkVMBlitter.)

Other next steps may involve factoring the pipeline's implicit
use-the-paint-color shader into an explicit shader.

Just FYI on the bug, thinking along its lines.

Bug: skia:9572
Cq-Include-Trybots: skia.primary:Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-SK_USE_SKVM_BLITTER
Change-Id: Ia9a5a10d685d2ca0a5e15792c7cf39d8b32a20a4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252022
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-11-01 17:48:50 +00:00
Stephen White
40c47e113d Dawn: fix RTHeight adjustment.
When rendering to a BottomUp render target, the SRIR-V codegen
needs a uniform to pass the render target height. (This is kind
of hacky, since it depends on being the last uniform, but it's
the same hack that the Vulkan backend uses.)

Change-Id: I520478d5e26504c7884daa72024fafe943a07294
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252182
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Stephen White <senorblanco@chromium.org>
2019-11-01 17:41:49 +00:00
Robert Phillips
0a4681d044 Reduce max # of AA Quads that can be merged or chained into a single GrTextureOp
It is, arguably, not a good metric but the max number of AA Quads that are merged or chained together across all Skia's GMs and SKPs is 276.

This should also reduce the memory consumed from 245,760 bytes to 30,720 bytes.

Bug: b/143572065
Change-Id: Ia70d3671fa33e0d84b38b4788e8c74ef98a9661e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252176
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2019-11-01 17:29:48 +00:00
Hal Canary
5e5f9dc32b tools/git-sync-deps: enforce commit hash in DEPS, not tags or branches
Change variable name to reflect that.

Also, pass '--no-checkout' to git-clone to suppress "warning: remote
HEAD refers to nonexistent ref, unable to checkout" error message.

Also, change '@' to '>' in verbose output if anything changes in the
repositories.

Change-Id: I27d0b026d121c163e378f34ab2bbe81233ddba1a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252177
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2019-11-01 17:22:40 +00:00
Greg Daniel
524e28b88f Use GrSurfaceProxyView for dst proxies.
Bug: skia:9556
Change-Id: I41ae112a3d22f6c6481cba1afc3937b5e5115cf5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252043
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-11-01 17:18:19 +00:00
Mike Klein
ed2cec4b68 add --quick to fm
This is handy for cutting irrelevant tool costs from a CPU profile.

Change-Id: Ib1d5a64a01866333e4e83351571dcb7c282ee9dc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252152
Commit-Queue: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2019-11-01 16:24:44 +00:00
Michael Ludwig
61eba6c74a Remove extraneous semicolons
This lets skia_renderer include SkBlendModePriv.h without breaking the
chrome build.

Change-Id: Icb96dbc50199c3a98bc7d5d2b643afda0297cf97
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252178
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-11-01 16:12:04 +00:00
Mike Klein
23e856f369 add GM for exercising interesting paths in SkVMBlitter
It's not drawing anything earthshattering, but it does act as an easy
way to exercise some interesting code paths in SkVMBlitter, here first
program caching based on shader program and not shader identity.

With today's shader caching patches, this makes 2 calls to
skvm::Builder::done(), JITing the program, while if you patched this in
at head you'd see 3.  I'd like it to get down to 1 by converting paint
colors to color shaders.

Change-Id: I042f4d44a792b46e5543794c853e4ef0d95b11ec
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252029
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-11-01 15:39:34 +00:00
Mike Klein
2368bda0e1 try hashing shaders via their program
1) add a hash() method to skvm::Builder
     This is cheap... we're hashing instructions as we go anyway.
     Small refactoring to keep all its hashing close and clear.

  2) split Key into Key (a small bytey hashy identifier)
     and Params (a pointery typey payload struct)

  3) dummy call ->program() on shaders as we build our Key,
     and then include that dummy Builder's hash() in the key.

This lets us reuse cached programs when effects vary only in their
uniforms.  The approach in 3) is meant to be a first draft, a kind of
can-we-get-away-with-this hack.  We may need to change this with,
    - stronger equality than just a hash of the instructions;
    - a new cheaper hook that avoids the cost of skvm::Builder.

Cq-Include-Trybots: skia.primary:Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-SK_USE_SKVM_BLITTER
Change-Id: I5f3839d3f7de40043fcb6177b617672c56f0eb70
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252019
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-11-01 15:32:44 +00:00
Brian Osman
2b73e66ca5 Add BT2020 (non-constant-luminance) YUV color space
Change-Id: I8ef13b78a5f2f49ff9c59db285b3e0e7ee708c9b
Bug: chromium:960620
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252160
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2019-11-01 14:34:13 +00:00
Brian Osman
25feadb636 Remove SK_LEGACY_YUV_MATRICES
Chrome has been rebaselined:
https://chromium-review.googlesource.com/c/chromium/src/+/1893372

Change-Id: Iff21ca606bf2e5fa0b8946940cab0b06fbd11e47
Bug: skia:9543
Change-Id: Iff21ca606bf2e5fa0b8946940cab0b06fbd11e47
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252158
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-11-01 14:21:01 +00:00
Robert Phillips
fd0c3b513e Update GrTextureOp to use index buffer offsets for draws
This should, hopefully, be faster on GL as we will only need to update the index-range for a draw rather than the offset into an vertex buffer.

Change-Id: I09e54c37262168661443fa8bf8d3b43cd8faa9db
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251757
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2019-11-01 14:09:43 +00:00
Eric Boren
2540704a38 [infra] Update git, make [Canvas|Path]Kit et al use git from CIPD
These docker-based tests don't actually need a checkout, but removing it
is proving time consuming and syncs are timing out.

Probably related to skia:9588

Bug: skia:9588
Change-Id: I39532f1d9cd1f6116fab341e648a517b98a312c2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252156
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-11-01 13:40:23 +00:00
skia-autoroll
680b490426 Roll third_party/externals/angle2 841b01678c49..e96039218e9d (6 commits)
841b01678c..e96039218e

git log 841b01678c49..e96039218e9d --date=short --no-merges --format='%ad %ae %s'
2019-11-01 jmadill@chromium.org Capture/Replay: Correct a few GLenum replay issues.
2019-10-31 jmadill@chromium.org Capture/Replay: Implement GetFramebufferParameter capture.
2019-10-31 jmadill@chromium.org Win: Add ANGLE_WAIT_FOR_DEBUGGER option.
2019-10-31 sugoi@google.com Provoking vertex feature support enabled
2019-10-31 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/SwiftShader e1cda3916cee..fda994c63075 (2 commits)
2019-10-31 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/spirv-tools/src 7e2cba6a5241..618ee509421f (3 commits)

Created with:
  gclient setdep -r third_party/externals/angle2@e96039218e9d

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-skia-autoroll
Please CC jcgregorio@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Bug: None
TBR=jcgregorio@google.com
Change-Id: I524b07247c46f62a93673e9cef42425b68546f38
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252136
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-11-01 11:44:13 +00:00
recipe-roller
8f062cdaa7 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
recipe_engine:
  https://crrev.com/afc73d4e075d241d52b01b744e73111ee3f0c47c [buildbucket] Support custom field masks (smut@google.com)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: If8093d028fa1e3b81d631257859787530eef16c5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252120
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-11-01 08:50:23 +00:00
recipe-roller
7f680a638e Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
depot_tools:
  https://crrev.com/86244d69136428f214950605d82533229b18098e [lucicfg] Update from v1.8.6 to v1.11.4. (vadimsh@chromium.org)
  https://crrev.com/4861444124e0dba81e9bf74798cebbd01f19f744 Specify open file encoding explicitly. (yura.yaroshevich@gmail.com)
  https://crrev.com/b96466297216f5b7c1df73df7771e6234e64552d presubmit_support: Set python_executable to vpython. (ehmaldonado@chromium.org)
  https://crrev.com/419c92f1bc931e5d1b3f1346e82c1cfa7612f783 gclient_utils: Make FileRead always return a Unicode string. (ehmaldonado@chromium.org)
  https://crrev.com/5bfa3ae88d76e1db57cf0bdc0a366c59f0dae641 gerrit_util: Refactor ReadHttpResponse and add more tests. (ehmaldonado@chromium.org)
  https://crrev.com/e79107e01bb48ae8b2430db4b36d1dbe104817f9 gclient_scm: Fix tests on windows (ehmaldonado@google.com)
  https://crrev.com/ebba8d75bf65250198a1f5c84295e119129915bd Add more tracing to git cache. (erikchen@chromium.org)
  https://crrev.com/27eb01c35517ac2bb4974e9c03517ad271b7a2ce Revert "gerrit_util: Refactor ReadHttpResponse and add more tests." (ehmaldonado@chromium.org)
  https://crrev.com/4ba192e7a9c8d3d559906b7fb92c5c108d7d6bfa Reland "gerrit_util: Refactor ReadHttpResponse and add more tests." (ehmaldonado@chromium.org)
  https://crrev.com/fea4a2548205e7a53642c4494d2d6c5829ec2471 Roll depot_tools git to v2.23.0 [bleeding edge/canary] (erikchen@chromium.org)
  https://crrev.com/5eb757a74239ab46dd7953ef18a6400f9cfbe997 Skip non-text files for CheckDoNotSubmitInFiles (hypan@google.com)
  https://crrev.com/512f92b73181c8e1d99d38cd9b73fbf41151636a Fetch the input commit ref when both ref and id are specified. (gbeaty@chromium.org)
  https://crrev.com/1e4dbf3f6432b8bf0a06877b8ae0ddd92a311197 Add more git tracing. (erikchen@chromium.org)
  https://crrev.com/27bd4e420d28f93db63e35479caaad72442e72d9 Reland "put goma client in depot_tools" (ukai@google.com)
  https://crrev.com/b43d98bf64843cf59c60732de21b7c07f0ed302e auth: Fix has_luci_context_local_auth. (ehmaldonado@chromium.org)
  https://crrev.com/48823c28549dd8055e16e4046215b929cd1eaeec Revert "Add more git tracing." (jbudorick@chromium.org)
  https://crrev.com/7a7798433110cd7ab1209bea46dd99806b82ba95 Revert "Fetch the input commit ref when both ref and id are specified." (hypan@google.com)
  https://crrev.com/c9144527d9f37bbd59e8776150d99adf23f072a5 depot_tools: Don't use basestring in scm.CaptureStatus. (ehmaldonado@chromium.org)
  https://crrev.com/48cda092cd869135948444c156478185289104ab gerrit_util: Remove RemoveReviewers. (ehmaldonado@chromium.org)
  https://crrev.com/9bb7b96c4d22f66abc0ce1dba5c94b989e4cb72a git-rebase-update: Make tests run on Python 3. (ehmaldonado@chromium.org)
  https://crrev.com/14705d8ce06addc9b6abfe6b2d75c4fe96a3b8a2 depot_tools: Make owners tests run on Python 3 (ehmaldonado@chromium.org)
  https://crrev.com/b983024505141c9abd2b75d515e64e2a77ccf07e presubmit_support: Fix tests on Python 3. (ehmaldonado@chromium.org)
  https://crrev.com/c87ed60623e4f057620552a9dc754c9c9f1e02e7 git-cl: Fix some python3 compatibility errors. (ehmaldonado@chromium.org)
recipe_engine:
  https://crrev.com/fa1af6362953b8c5c24e3082b0081e688f2be32d [swarming] Add tags to swarming task request. (ihuh@google.com)
  https://crrev.com/5f5aea33b7cac05bfc7f7b68332de60ddd143be3 Roll swarming go client (dcheng@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: If2f536b7581c2bb9393bdbaf31818e96c4e30ece
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251941
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-11-01 01:22:42 +00:00
Emircan Uysaler
283ec65f63 Handle all failures for vkWaitForFences
Bug: chromium:1019469
Change-Id: Ic32be65775cf6b7d3261d1d8b4076363d0e65874
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251821
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2019-10-31 20:23:50 +00:00
Herb Derby
f5ad3f421e Fast SkPackedGlyphID CTOR
Performance measurments showed that SkPackedGlyphID was too much
time.

SkDiffBench-lorem_ipsum 955µs -> 873µs

BUG=chromium:881505

Change-Id: I8d42f02d87817777cc7c95404c73c723f0bc100c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251818
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2019-10-31 20:11:20 +00:00
Michael Ludwig
b4577fb2cf Use point to line distance instead of area for colinear check
Bug: chromium:1018218
Change-Id: I9a33332a06a63075dd016f038d5cd4ede59f9a5d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252042
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2019-10-31 19:56:50 +00:00
Ben Wagner
5b6ccbb6b5 [infra] Upgrade MacBookAir to 10.15.
Also add a NativeFonts GPU bot pending the availability of CPU bots
(https://bugs.chromium.org/p/chromium/issues/detail?id=1018242).

Change-Id: I16c19ae2e05be16b622c14289e255d0a342c0654
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251817
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2019-10-31 19:26:28 +00:00
Herb Derby
ce8adae49e ...finally!
Change-Id: I31e9f0a06cf5541fe7b65924bfde85ee119b499e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/252037
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-31 18:43:22 +00:00
Michael Ludwig
fb7ba52344 Move tessellation math into GrQuadUtils
Change-Id: I133fb0d5e154c2f01aba7ef2a7e1b87b6089a608
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251460
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2019-10-31 17:30:33 +00:00
Ben Wagner
ac65db506d Add Pixel4 jobs
Change-Id: Ic112266665f5ef3512a7904b181862ea2eb009b2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251816
Commit-Queue: Ben Wagner aka dogben <benjaminwagner@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Auto-Submit: Ben Wagner aka dogben <benjaminwagner@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2019-10-31 17:25:54 +00:00
Hal Canary
7823aeb8d6 refactor/layering: SkMalloc.cpp
Change-Id: Ie27c9f0ba2b9f160010d33548dc8359851610d79
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251819
Commit-Queue: Hal Canary <halcanary@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2019-10-31 15:49:03 +00:00
Mike Klein
2eae8e53ba only scale shader by paint alpha < 1
This adds `shader && paint alpha < 1.0f` to the blitter Key, so we'll
generate and cache two different programs based on that bit.

I put a little bit of effort into a different approach, wrapping the
shader with a new shader that modulates by paint alpha when paint alpha
is less than one.  This should work, but I realized that it would break
caching, since we're caching based on shader identity.  (Not really
break, but make it ineffective.)

I've added some notes about cache keys in general, and that this wrapper
approach would make caching less effective is I think enough to make me
want to work out a "identify yourself except for uniforms" protocol for
shaders (really effects, eventually color filters will need it too).

Change-Id: I1a2a490657bf7442e79f87d80968302720265f7d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251775
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-31 15:27:53 +00:00
Mike Klein
e2333d7714 fix uniform buffer size, scale by paint alpha
Brace initilaization of a std::vector was starting our uniform buffer
out as a single byte, holding sizeof(Uniforms).  I meant it to be
sizeof(Uniform) bytes, all zero...

That's fixed here, and was why scaling by paint alpha wasn't working.

Change-Id: Iad30d701aa175c74c9c5aaed8baf8279479188b1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251753
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
2019-10-31 15:22:33 +00:00