Commit Graph

54152 Commits

Author SHA1 Message Date
Andy Weiss
8b6d943d91 Override delete for GrOp
We are seeing a crash in a flutter desktop linux application with the
the issue pointing to a sized delete mismatch:

debugallocation.cc:788] RAW: delete size mismatch: passed size 160 !=
requested / available size 192 / 192

This patch fixes the issue. The crash started after the roll that
brought in https://skia-review.googlesource.com/c/skia/+/382701

See fxbug.dev/71987 for more info

Change-Id: I635ce5190d82ea96e1070e0509e543934379b776
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383456
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-03-11 14:36:37 +00:00
John Stiles
f3a28db703 Eliminate control-flow analysis.
We no longer derive a performance benefit from this pass in practice,
and it is a very expensive compilation step. It is also prone to fuzz-
related errors.

Doc: http://go/optimization-in-sksl

Change-Id: Ief08ffac659a8fe7fe92c92b9a5da14c9f713bc2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381261
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-03-11 13:24:54 +00:00
Greg Daniel
80ef70e8f5 Make sure we check for abandoned when with getBackendSurface calls.
Previously even if we release/abanoned a resource we would still return
GrBackendSurfaces from these queries even if the actual backend api
objects are no longer valid.

This hopefully fixes the attached chrome bug, but can't know for sure.

Bug: chromium:1186623
Change-Id: Ib1c03699c2c7d81f6d305428dfbf39d647d28373
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382918
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2021-03-11 13:02:17 +00:00
skia-autoroll
551bae6843 Roll Dawn from 6d4617a2d28d to b458fc835925 (4 revisions)
https://dawn.googlesource.com/dawn.git/+log/6d4617a2d28d..b458fc835925

2021-03-10 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 6ce58becd2d5 to d9250a5a2175 (2 revisions)
2021-03-10 cwallez@chromium.org codereview.setings: default to not squashing on git cl upload
2021-03-10 shrekshao@google.com Add tests for zero sized index buffer out of bounds draw test
2021-03-10 rharrison@chromium.org Add reflection for used vertex attributes using Tint

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from 6ce58becd2d5 to d9250a5a2175

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dawn-skia-autoroll
Please CC kainino@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Debug-Dawn
Bug: None
Tbr: kainino@google.com
Change-Id: I4012a14c8667f7a56e7549f19968f8ba9219ee60
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383458
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-11 07:00:03 +00:00
skia-autoroll
43bde9d2bc Roll SwiftShader from 023914a27b63 to a2fe8e1b2111 (1 revision)
https://swiftshader.googlesource.com/SwiftShader.git/+log/023914a27b63..a2fe8e1b2111

2021-03-10 srisser@google.com Add Vulkan 1.2 entry points

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 kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Test-Debian10-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
Tbr: kjlubick@google.com
Change-Id: I038038d8f94ef84412f22120f970375b86c6c45c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383459
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-11 05:11:33 +00:00
skia-autoroll
a2cae875c0 Roll ANGLE from c054008f9efb to 44b9579cf7b8 (12 revisions)
c054008f9e..44b9579cf7

2021-03-10 m.maiya@samsung.com Vulkan: Treat varyings in a separable program as active
2021-03-10 ianelliott@google.com Revert "Roll vulkan-deps from 6691fcec0bce to 32692e5de307 (12 revisions)"
2021-03-10 jonahr@google.com Mtl: Add Apple vendor ID
2021-03-10 ianelliott@google.com Revert "Roll vulkan-deps from 32692e5de307 to 28d8c3478e4c (6 revisions)"
2021-03-10 m.maiya@samsung.com Vulkan: Pass in the correct size to acquireBufferHelper
2021-03-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from 32692e5de307 to 28d8c3478e4c (6 revisions)
2021-03-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 031d7b5c5879 to 075d29b4983b (268 revisions)
2021-03-10 lubosz.sarnecki@collabora.com capture_replay_tests: Change status to crashing.
2021-03-10 lubosz.sarnecki@collabora.com capture_gles_ext_params: Implement glGetIntegervRobustANGLE.
2021-03-10 syoussefi@chromium.org Vulkan: Fix MemoryBarrier function name typos
2021-03-10 syoussefi@chromium.org Vulkan: Move SpirvBlob definition to common/
2021-03-10 syoussefi@chromium.org Vulkan: Create unresolve shader directly in SPIR-V

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 kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Release-ANGLE;skia/skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Tbr: kjlubick@google.com
Test: Test: ProgramPipelineTest31.VaryingIOBlockSeparableProgram*
Change-Id: Ice60be3d3cbb768e0ab5861cb72d46262431dfef
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383476
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-11 04:52:33 +00:00
skia-autoroll
6ee144f218 Roll Chromium from 9bc5c82512d2 to c62ff0ef3797 (416 revisions)
9bc5c82512..c62ff0ef37

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/chromium-skia-autoroll
Please CC kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia/skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Tbr: kjlubick@google.com
Change-Id: I073c3d88d7e6c7021486860adeb6081d932c2fa7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383457
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-11 04:48:53 +00:00
Chris Dalton
2603c1fb14 Delete coverage counting backend from ccpr
This declutters the atlas generation code so there are fewer variables.
Next we will delete all the lower level rendering code and render the
atlas with stencilPath/stencilRect instead.

Bug: chromium:1158093
Change-Id: I36cff285d0f7de6f8ece4b027e62ae84aa01adc8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380656
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-03-11 04:26:00 +00:00
John Stiles
04a8a54ff9 Ensure all local variables exist in the ProgramUsage map.
Previously, a declared then never-read variable was not present at all.
This also adds an `fDeclared` field to VariableCounts, which tracks the
presence of a VarDeclaration for a variable. `fDeclared` allows us to
distinguish between the cases of a declared but completely inert
local variable, and a variable whose declaration has actually been
eliminated.

Change-Id: I1d7238a257997814e0d978d76b98005541b8a6bc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383156
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-03-11 01:36:36 +00:00
Heather Miller
cc185c5a31 update schedule with 4 weeks, 2021 dates
Change-Id: Ic35cad32be132e7e6f8eb5dc84d3b3eb775d13a6
No-Try: true
Docs-Preview: https://skia.org/?cl=383236
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383236
Reviewed-by: Heather Miller <hcm@google.com>
Commit-Queue: Heather Miller <hcm@google.com>
Auto-Submit: Heather Miller <hcm@google.com>
2021-03-11 00:27:48 +00:00
Chris Dalton
368acf940f Disable ccpr on Adreno405 and Adreno418
Hopefully this is only temporary until we start using the default path
renderers to draw the atlas.

Change-Id: Ife2c5bccd0cd7a980bde8faa5178f9fb151fbdff
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383017
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-03-11 00:18:34 +00:00
Mike Reed
d0ce14942b Return null if clipshader fails
This allows us to try skvm blitter, which might succeed with
the clipshader.

Change-Id: I771d4d389ae59ffd76e742cd223798f17582fedc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383096
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2021-03-10 23:31:59 +00:00
Chris Dalton
be54c66cdd Disable ccpr clip atlas when --reduceOpsTaskSplitting is enabled
Bug: skia:11731
Change-Id: Ia676f0db9092596f28739dbd083d9a4bc8b67878
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383119
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-03-10 23:02:44 +00:00
Greg Daniel
9b6e30bd67 Fix deleting of GrGpuResource when abanonded and refs go to zero.
Abandoning would cause us to unref all the command buffer usages, but
then in notifyARefIsZero we would delete the abandoned resources even
though we still had a real ref. Then when that ref went away we would
crash.

Change-Id: I05dc2ba9a67c35c36a36704f4b81d6eef4e860e6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382916
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2021-03-10 20:53:23 +00:00
Herb Derby
93330c9c4d Reland "Reland "cache the creation of one GrAtlasTextOp""
This is a reland of dc3d678712

All previous attempts tried to use variants of
thread_local std::unique_ptr<char> gCache;

This did not work on Android or Flutter because thread_local
variables with dtors failed in various ways.

This CL keep the cache from leaking bytes by clearing the
cache in the GrRecordingContext's destructor.

Original change's description:
> Reland "cache the creation of one GrAtlasTextOp"
>
> This is a reland of 4b1fb7ca90
>
> Original change's description:
> > cache the creation of one GrAtlasTextOp
> >
> > GrAtlasTextOp has a high probability of being merged with the
> > previous op. This cache keeps using the same op to merge with
> > keeping memory warm.
> >
> > This show about 5.75% improvement in skpbench on desk_nytimes.
> >
> > When compiling for ios 9 or earlier, this optimization is
> > disabled.
> >
> > Change-Id: I13ccbef6dcd4b9d82103bf20bba7d94f3e4fb6f4
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/376718
> > Reviewed-by: Michael Ludwig <michaelludwig@google.com>
> > Reviewed-by: Brian Salomon <bsalomon@google.com>
> > Commit-Queue: Herb Derby <herb@google.com>
>
> Change-Id: I935a2965062b1fddb28806e85eb0fe055ba46ec2
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380320
> Commit-Queue: Herb Derby <herb@google.com>
> Reviewed-by: Michael Ludwig <michaelludwig@google.com>

Change-Id: I62f572583524c506488ba982f5047a8f0126f3dc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382701
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-03-10 19:22:14 +00:00
John Stiles
f71a136ba9 Remove busywork from nameExpression.
It was copying strings back and forth for no benefit.

Change-Id: I5ee2c0a6d1d0f96fb7449d1e540e4d9db0d97dc2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382776
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-03-10 18:57:15 +00:00
Florin Malita
baab5aff09 [skottie/wasm] Plumb text properties in WASM bindings
Only text string + size for now, we can surface more if needed.

Change-Id: I4b40c1bb5e27ea5fc4ed20a1214c4eeb04bf1ca8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382279
Commit-Queue: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Jorge Betancourt <jmbetancourt@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2021-03-10 18:34:04 +00:00
Jim Van Verth
c9fb49a55f Add destructor override
Change-Id: Ide8d7d0f91748fc1e2235cf94f310f6d51084ee3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382759
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: Jim Van Verth <jvanverth@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-03-10 18:32:34 +00:00
John Stiles
9c4cdef7e5 Fix gm slide 'TessellationTestRectShader'.
This needed to be updated to match changes in
http://review.skia.org/382476. It is not tested on any of the normal
CQ trybots.

Change-Id: I3c0843d8e77958192c0db9ad8f6b797aec887fe4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382757
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-03-10 17:38:18 +00:00
Jim Van Verth
e82fdaa50b Accept near-simple, near-circular rrects for shadow fast path.
SkRRectPriv::IsSimpleCircular does a tolerance-based check for the
rrect radii but not for determining if the rrect is simple. This adds
IsNearlySimpleCircular as a looser check, since we don't care in this
case that the rrect is perfectly simple.

Bug: skia:11717
Change-Id: Ibbd53ff8c120287339fa29f87f064e6fb633ee7c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382703
Reviewed-by: Leon Scroggins <scroggo@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-03-10 17:30:34 +00:00
John Stiles
376a478996 Fix StencilResolveProcessor to declare its outputs.
This crossed in the mail with http://review.skia.org/382476

Change-Id: I09ca2ff20bb2dc0846b591893d06823577faea29
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382758
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
2021-03-10 17:00:46 +00:00
Jim Van Verth
534c8c5f61 Update Metal PipelineStateCache to use new stats tracking
Change-Id: I3edc1812f74319abeb13d94cf7e2426bd68b57a3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382282
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2021-03-10 16:45:05 +00:00
Chris Dalton
1e7b2e5e17 Re-enable ccpr clipping for small paths
For things like path rendering we can (and should) do better than an
atlas. But for use cases like "many small paths clipped by many small
paths," an atlas is probably still the best solution we have.

Change-Id: Iff5d250d0d6ccba9235f3fe652891554e3fdfc24
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380856
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-03-10 16:22:58 +00:00
John Stiles
4d7ac49dca Declare outputColor and outputCoverage inside emitCode.
This is useful because it allows the variables to be declared as `const`
when they are trivial values like `half4(1)`. This enables the constant
folder to simplify or eliminate them. In most cases, this is only a
small benefit, as you'd expect a competent GPU driver to do the same.
However, Mali-400 can benefit significantly from optimizing away the
multiplication against a constant half4(1) coverage in Porter-Duff.

Mali-400 performance is back to normal: http://screen/3cDxdaGkYE8oBcS

Change-Id: I21fd23f91f747079cd05b082f7b3444aeabafb93
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382476
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-03-10 16:03:18 +00:00
John Stiles
38847cda89 Remove unnecessary scope from fragment shaders.
This block no longer appears to provide any benefit; we mangle variable
names to prevent name collisions already.

Change-Id: I970a9d55ed5a77b93ff611e6a58e9424db78f6db
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382396
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-03-10 15:46:38 +00:00
John Stiles
be6cbf331c Disable constant-variable substitution when optimization is off.
When optimization is disabled, I did not expect to see arithmetic like
`color * ONE` disappear (even though it's just a constant fold):

    const vec4 ONE = half4(1);
    vec4 x = color * ONE;

Change-Id: Id24a632712591c73a904b90e5efdba092d846c0e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382477
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-03-10 15:44:48 +00:00
John Stiles
0dd1a77e12 Add noinline keyword to SkSL.
As you might expect, a function tagged with `noinline` will never be
considered as a candidate for inlining.

Change-Id: Ia098f8974e6de251d78bb2a76cd71db8a86bc19c
Bug: skia:11362
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382337
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-03-10 15:39:48 +00:00
skia-autoroll
da076e9aca Roll Chromium from 5d94010048eb to 9bc5c82512d2 (404 revisions)
5d94010048..9bc5c82512

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/chromium-skia-autoroll
Please CC kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia/skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Tbr: kjlubick@google.com
Change-Id: I9c81d056c36e255408617d0ac618c537d554d985
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382496
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-10 05:37:07 +00:00
skia-autoroll
44fb2f3151 Roll ANGLE from 9bc9ac8df8df to c054008f9efb (16 revisions)
9bc9ac8df8..c054008f9e

2021-03-09 m.maiya@samsung.com Vulkan: Check buffer usage before unmapping
2021-03-09 cnorthrop@google.com Tests: Add Extreme Car Driving Simulator trace
2021-03-09 cnorthrop@google.com Capture/Replay: Fix compressed cube textures
2021-03-09 m.maiya@samsung.com Vulkan: Collect inactive varyings by block name for I/O blocks
2021-03-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 76f6150ffdeb to 031d7b5c5879 (832 revisions)
2021-03-09 m.maiya@samsung.com Call resolveLink in Program::attachShader and Program::detachShader
2021-03-09 ynovikov@chromium.org Update Xcode used by standalone Mac builders to 12.4
2021-03-09 ianelliott@google.com Work-around eglSwapBuffersWithDamageKHR() bug
2021-03-09 jmadill@chromium.org Allow graceful no-error failure in CastStateValues.
2021-03-09 penghuang@chromium.org Reland "Fix bindFramebuffer problem with GLES2 devices"
2021-03-09 penghuang@chromium.org Reland "Fix two issues with GLES2 devices"
2021-03-09 penghuang@chromium.org Revert "Vulkan: Support EXT_sRGB_write_control"
2021-03-09 penghuang@chromium.org Revert "Fix bindFramebuffer problem with GLES2 devices"
2021-03-09 penghuang@chromium.org Revert "Fix two issues with GLES2 devices"
2021-03-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from de7d5775ab25 to 023914a27b63 (2 revisions)
2021-03-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from 6691fcec0bce to 32692e5de307 (12 revisions)

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 kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Release-ANGLE;skia/skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Tbr: kjlubick@google.com
Test: Test: Black Desert MobileTest: Test: GLSLTest_ES31.VaryingIOBlockNotDeclaredIn*Shader*Test: Test: Grand Theft Auto: San AndreasTest: Test: MEC for Extreme Car Driving SimulatorTest: Test: angle_perftests --gtest_filter="*extreme_car_driving_simulator*"
Change-Id: I2ad7a6ee32d4a6331d0a1bd225b52684a2bc21a5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382516
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-10 04:46:27 +00:00
skia-autoroll
beb62fb11c Roll Dawn from 010fd1a8d7c7 to 6d4617a2d28d (3 revisions)
https://dawn.googlesource.com/dawn.git/+log/010fd1a8d7c7..6d4617a2d28d

2021-03-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from fe2ceb9b5d7c to 6ce58becd2d5 (13 revisions)
2021-03-09 bclayton@google.com ShaderModule: Use transform::Renamer
2021-03-08 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 13ee0fbdf337 to fe2ceb9b5d7c (2 revisions)

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from 13ee0fbdf337 to 6ce58becd2d5

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dawn-skia-autoroll
Please CC kainino@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Debug-Dawn
Bug: None
Tbr: kainino@google.com
Change-Id: I17c8adb121f5003ae518accea3c38f7bcfdb51f6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382536
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-10 04:41:27 +00:00
Herb Derby
cc1cbcf9e0 Revert "Reland "cache the creation of one GrAtlasTextOp""
This reverts commit dc3d678712.

Reason for revert: Crashing on exit thread handler

Original change's description:
> Reland "cache the creation of one GrAtlasTextOp"
>
> This is a reland of 4b1fb7ca90
>
> Original change's description:
> > cache the creation of one GrAtlasTextOp
> >
> > GrAtlasTextOp has a high probability of being merged with the
> > previous op. This cache keeps using the same op to merge with
> > keeping memory warm.
> >
> > This show about 5.75% improvement in skpbench on desk_nytimes.
> >
> > When compiling for ios 9 or earlier, this optimization is
> > disabled.
> >
> > Change-Id: I13ccbef6dcd4b9d82103bf20bba7d94f3e4fb6f4
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/376718
> > Reviewed-by: Michael Ludwig <michaelludwig@google.com>
> > Reviewed-by: Brian Salomon <bsalomon@google.com>
> > Commit-Queue: Herb Derby <herb@google.com>
>
> Change-Id: I935a2965062b1fddb28806e85eb0fe055ba46ec2
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380320
> Commit-Queue: Herb Derby <herb@google.com>
> Reviewed-by: Michael Ludwig <michaelludwig@google.com>

TBR=bsalomon@google.com,herb@google.com,michaelludwig@google.com

Change-Id: I3bc3329580460fcf8c0b49f655a88cb902da3d58
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382556
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-03-10 04:24:09 +00:00
Herb Derby
dc3d678712 Reland "cache the creation of one GrAtlasTextOp"
This is a reland of 4b1fb7ca90

Original change's description:
> cache the creation of one GrAtlasTextOp
>
> GrAtlasTextOp has a high probability of being merged with the
> previous op. This cache keeps using the same op to merge with
> keeping memory warm.
>
> This show about 5.75% improvement in skpbench on desk_nytimes.
>
> When compiling for ios 9 or earlier, this optimization is
> disabled.
>
> Change-Id: I13ccbef6dcd4b9d82103bf20bba7d94f3e4fb6f4
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/376718
> Reviewed-by: Michael Ludwig <michaelludwig@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Herb Derby <herb@google.com>

Change-Id: I935a2965062b1fddb28806e85eb0fe055ba46ec2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380320
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2021-03-09 23:32:00 +00:00
Brian Osman
86e85537fe Test that we propagate 'const' to the GPU backend of runtime effects
Currently, only one of three uses (local variables) does this correctly.

Bug: skia:11716
Change-Id: Iad11e8e5998fcc7caee4d438e0558c5d4e2b1821
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382277
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-03-09 23:26:00 +00:00
Michael Ludwig
a5c90588b1 Consistently fail writePixels when rowbytes not a multiple of bpp
With skia-review.googlesource.com/c/skia/+/363782, both cpu and gpu
backends would gracefully fail readPixel requests where dst row bytes
wasn't a multiple of dst bpp. It also updated the cpu backend's
writePixels behavior to gracefully reject writePixels requests where
the src row bytes wasn't a multiple of src bpp.

GPU writePixels would not detect this and later trigger an assert
in debug builds in GrConvertPixels (caught by the linked fuzzer bug).

This adds tests to mirror the read pixels bad-row-bytes tests and
updates GrSurfaceContext::writePixels to check src row bytes vs. bpp.
I confirmed it fixes the fuzzer crash.

Bug: chromium:1185266
Change-Id: I7cd8406c65a9ba35a55d695b2f65410a1edd2a19
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/382276
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2021-03-09 21:54:50 +00:00
Jim Van Verth
7d195fff45 Cache precompiled MSL shaders.
Acts similarly to the GL precompiled shaders, in that it will cache
preliminary data (in this case, the MTLLibraries) in the PipelineState
cache, and then when the pipeline is built will extract that. Once
the pipeline is built the MTLLibraries are discarded.

Bug: skia:11392
Change-Id: I701e2e857d105c9149a2f69fe7b60bf4599195bc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380457
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-03-09 21:10:22 +00:00
John Stiles
c3ce43be8e Replace the vector<Statement> in SwitchCase with a Block.
Change-Id: Ic2d1240ab785101365b0fd934562505fb5a3e599
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381816
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-03-09 20:46:10 +00:00
Ethan Nicholas
24c1772ea4 Fixed an issue with DSL includes
It turned out that everywhere we were using or testing DSL code either
directly or indirectly imported big chunks of the SkSL library. These
imports turned out to be necessary; code written using just DSL.h would
fail with various template instantiation errors.

Change-Id: Iae72d15b0d6ef14614ac1a4ff08c36bc1876cd4d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381638
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-03-09 20:07:00 +00:00
Herb Derby
6447784a31 encapsulate GrTextBlob::Key creation into Key::Make
Change-Id: Iabd75ca316e7f0ae28d2fc24d29d42db804ed8d4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381636
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
2021-03-09 19:59:56 +00:00
Adlai Holler
5be0eca849 Remove a few unneeded retain & autoreleases from Metal
We should avoid convenience factory methods when possible, to
keep things out of the autorelease pool.

Change-Id: I0a042b59619aff7a91b889add4ad341ab892809a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381860
Auto-Submit: Adlai Holler <adlai@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2021-03-09 18:49:00 +00:00
Peng Huang
0408afc573 Fix GrGpuBuffer::onRelease() crash problem.
The crash is because method GrGpuBuffer::onRelease() is called on wrong
thread. SkMessageBus::Post(const Message& m) takes a const ref of the
message, so there is a little possibility the GPU thread received and
handled the message before SkMessageBus::Post() is returned. In that
case, the caller of SkMessageBus::Post() (AsyncReadResult) still holds
the last ref of the GrGpuBuffer, and then GrGpuBuffer() will just be
released on the wrong thread.

Bug: chromium:1185489
Change-Id: I28665dbb1db7925d59ec574e9e26385e845ff4df
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380696
Commit-Queue: Peng Huang <penghuang@chromium.org>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Auto-Submit: Peng Huang <penghuang@chromium.org>
2021-03-09 18:10:00 +00:00
Herb Derby
63fe8e53dd move subrun creation to GrTextBlob::Make
Change-Id: Iee920e3751e067ff3b86ed6713b279fc2437fd14
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381477
Reviewed-by: Brian Osman <brianosman@google.com>
2021-03-09 16:53:35 +00:00
Adlai Holler
01cb243b5e Always make unarchived SkMatrices thread-safe
This is sort of a nuclear option for matrices that are archived by e.g.
SkPictures, SkShaders, and SkEffects. But in all these cases, the
unarchived objects are const and ought to be thread-safe.

Bug: skia:11715
Change-Id: I0215f0fc988e9ce01efd4e200c9951c3b5be7da6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381519
Commit-Queue: Adlai Holler <adlai@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2021-03-09 15:44:30 +00:00
Jim Van Verth
6cb17ead60 Fix stencil format mismatch in GrMtlPipelineState creation.
We can have a stencil attachment on the RenderTarget with stencil disabled.

Bug: skia:11392
Change-Id: Iefc661e9206eb859b02e91857f3682a525493df6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380716
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-03-09 14:20:40 +00:00
Ethan Nicholas
b14b63623c Added unary + and - DSL operators
These were accidentally omitted from the supported operator list.

Change-Id: Idecd17adb8b3f5043e36328c65ca12be33e990f4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381637
Auto-Submit: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-03-09 14:19:03 +00:00
skia-autoroll
a850a4a6b2 Roll ANGLE from 9bc86c50f283 to 9bc9ac8df8df (11 revisions)
9bc86c50f2..9bc9ac8df8

2021-03-09 penghuang@chromium.org Disable worker contexts on Android emulator
2021-03-09 ynovikov@chromium.org Further suppress tests failing on Ozone.
2021-03-09 penghuang@chromium.org Fix bindFramebuffer problem with GLES2 devices
2021-03-08 lexa.knyazev@gmail.com Metal: Enable iOS pixel formats on macOS 11
2021-03-08 m.maiya@samsung.com Vulkan: Support EXT_sRGB_write_control
2021-03-08 penghuang@chromium.org Fix two GL_OES_texture_half_float related problems with GLES2
2021-03-08 ynovikov@chromium.org Add Win x86 chromium.angle bots to CQ
2021-03-08 penghuang@chromium.org Fix two issues with GLES2 devices
2021-03-08 lexa.knyazev@gmail.com Fix PVRTC1 frontend validation
2021-03-08 m.maiya@samsung.com Handle nullptr in GetQueryObjectParameter()
2021-03-08 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 6846389f25ca to de7d5775ab25 (1 revision)

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 kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Release-ANGLE;skia/skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Tbr: kjlubick@google.com
Change-Id: I3668505cd9de8e3a41193c8bd1643f84b468f4ed
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381857
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-09 05:27:59 +00:00
skia-autoroll
7d749cd578 Roll Chromium from 5cd489ad4ec5 to 5d94010048eb (4448 revisions)
5cd489ad4e..5d94010048

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/chromium-skia-autoroll
Please CC kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia/skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Tbr: kjlubick@google.com
Change-Id: Iba5c8471c5ee7d1aa9b07f5903554f6f95a3bb1e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381876
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-09 05:19:30 +00:00
skia-autoroll
2f37f2c260 Roll SwiftShader from de7d5775ab25 to 023914a27b63 (2 revisions)
https://swiftshader.googlesource.com/SwiftShader.git/+log/de7d5775ab25..023914a27b63

2021-03-08 srisser@google.com Add all Vulkan 1.2 feature structs
2021-03-08 swiftshader.regress@gmail.com Regres: Update test lists @ de7d5775

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 kjlubick@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Test-Debian10-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
Tbr: kjlubick@google.com
Change-Id: I8b84cd6f9320fe03712663fe783671e79f57333d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381856
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-03-09 05:09:10 +00:00
Adlai Holler
043a737317 GrResourceAllocator: cleanup after failed instantiation
Failed instantiations are ultra-rare, so instead of trying to return
early in that case, go ahead and finish iterating through the list
so that it's cleared out and the cleanup-assertions in the
destructor pass.

Bug: skia:10877
Change-Id: I1452e4521fb35a374a046e15df1fe33630f72df9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381756
Auto-Submit: Adlai Holler <adlai@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Adlai Holler <adlai@google.com>
2021-03-09 01:21:09 +00:00
Mike Reed
1cf56817f8 Remove supported for (removed) inheriting paint filter-quality
Bug: skia:7650
Change-Id: Ia4414d32b63b686b9987a7d1424c89fe57bd1afe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/380836
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
Auto-Submit: Mike Reed <reed@google.com>
2021-03-09 00:58:09 +00:00
John Stiles
5676c57220 Optimize away self-comparison in the constant folder.
Expressions like `value == value` or `color.a != color.a` can be
replaced by `true` or `false` on sight. The GLSL spec makes it clear
that checking for NaN is optional:

4.7.1 Range and Precision
"... NaNs are not required to be generated. Support for signaling NaNs
is not required and exceptions are never raised. Operations and built-in
functions that operate on a NaN are not required to return a NaN as the
result."

Change-Id: I2ad9f2dc505b638ea2904bef41b7a79a2b329551
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/381262
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-03-08 23:38:29 +00:00