Commit Graph

58184 Commits

Author SHA1 Message Date
Ravi Mistry
c0cfb1d5db Use new Canary flag in canary task driver
Bug: skia:12630
Change-Id: Ie4d4d9a62b4152b8ce3ebb5edebfe9aab88a2a25
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469858
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2021-11-10 17:37:57 +00:00
Herb Derby
a756c62097 move the GlyphVector into the subruns
Change-Id: I2ff2485e26b3fde8372dfab169f92672b965ba6e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469817
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-11-10 16:48:55 +00:00
Brian Salomon
8d6068493b Explicitly state that some draws ignore mask filter and path effect.
Bug: skia:12625
Change-Id: I8ad737855f25df83c85d619d69b006ccbd83658d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469897
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-11-10 16:29:56 +00:00
Brian Osman
dd50f0d6f2 Better handling of coverage-as-alpha during paint conversion
This is generally not a property of individual FPs in the shader tree,
it's a property of the root level FP, and how it applies alpha to the
color generated by the shader FP. So, two improvements:

  1) Remove all of the coverage-as-alpha inhibition happening in
     individual shaders.
  2) At the root of paint conversion, if there's a shader FP (and no
     primitive color), we either: use ApplyPaintAlpha, which *is* safe
     with coverage-as-alpha (updated flags to reflect this), or disable
     coverage as alpha (because our FP is now just generating a color and
     ignoring incoming alpha).

Note that we *could* choose to ALWAYS use ApplyPaintAlpha, even if the
paint color is opaque. That could result in extra (useless) work in some
situations, but it would enable the coverage-as-alpha optimization far
more often than we get it today.

Also: We don't change the behavior when there is a primitive color,
because that code path is already disabling coverage-as-alpha, thanks to
OverrideInput.

Change-Id: I1f040ee1217cf03e731ad1b8b497dc8e4df2de2b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469518
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2021-11-10 15:58:59 +00:00
Ravi Mistry
6e16bbaf79 Update go/skia.org/infra in go.mod/go.sum
To pick up canary commit msg change in buildbot repo

Updated with:
$ go get go.skia.org/infra@553519b41e
$ go mod download
$ make -C infra/bots train

Bug: skia:12630
Change-Id: Iba6dc47dd014d690b54b017a2f9d4d597ecf0d97
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469857
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2021-11-10 15:26:38 +00:00
Robert Phillips
09642f8aad Improve failure handling in directFilterMaskGPU
Bug: 1265434
Change-Id: I81af9fe52a981cfad3154de77aeee32b97b4d34c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469856
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2021-11-10 15:19:58 +00:00
Jim Van Verth
1c0d713153 [graphite] Add offsets to vertex buffers
Bug: skia:12466
Change-Id: Icf59f2412a66f3f339635014f4b1e4c44d3c1619
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469523
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-11-10 15:13:30 +00:00
Brian Osman
9481bba7a1 Remove alpha modulation from more shader FPs
No longer necessary - incoming alpha is 1.

Bug: skia:11942
Change-Id: Idf94e9de95dd233a0559efec4ed50c79e3b2da2b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469516
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2021-11-10 15:11:29 +00:00
Joe Gregorio
9ac4ee6457 Move Mac NativeFonts bots onto Macminis.
Change-Id: I0f7842c0aa7ac32bf26296d7eb9df772711a502e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/465716
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
2021-11-10 15:02:01 +00:00
John Stiles
6e6ae1b762 Fix inlined out-of-range vector access.
Previously, this code assumed that IndexExpression::Convert had done
range checking and that it was safe to access the base expression at
the passed-in index. The inliner violates this assumption, because it
can replace unknowns (where out-of-range access is undefined but non-
fatal) with knowns (where out-of-range access is forbidden).

We now do range-checking inside IndexExpression::Make and report the
error cleanly, instead of asserting inside of Swizzle::Make due to an
invalid component index.

Change-Id: If0f31b1f694bcc2a875d124f70be311d6634c77b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469535
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-11-10 14:44:38 +00:00
Kevin Lubick
0c23120abd [canvaskit] Switch to appropriate WebGL Context for Surface methods
Change-Id: Id829603bafb73d2256e44a9101b4b1669b735e12
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469534
Reviewed-by: Brian Salomon <bsalomon@google.com>
2021-11-10 13:49:24 +00:00
Brian Salomon
a55953c529 Fix assert in SkGradientShader IntervalIterator
We only can guarantee that the positions are strictly monotonic. The
assert was testing that pos n+1 minus pos n would produce a positive
value which may not be true if the subtraction underflows.

Bug: chromium:1267605
Change-Id: Iaeff8f83f901f9b5af990cc866bfc24fb4af921d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469522
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-11-10 13:46:58 +00:00
Herb Derby
d4edc0e2e4 make strikeToSourceScale consistent through the code
Change-Id: I2ad3493958f71186937efaea6da772523ae7c198
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469521
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-11-10 12:56:46 +00:00
skia-autoroll
97f72da16d Roll ANGLE from ee8e8a68c5a9 to 0b46ef407472 (24 revisions)
ee8e8a68c5..0b46ef4074

2021-11-10 lfy@google.com Vulkan: Start on a MapBufferRange benchmark
2021-11-09 cstout@google.com Allow GN specification of shared library extension name
2021-11-09 j.vigil@samsung.com EGL: EGL_KHR_lock_surface3 frontend
2021-11-09 j.vigil@samsung.com EGL: EGL_KHR_lock_surface3
2021-11-09 sdefresne@chromium.org [ios] Remove support for building with Xcode clang
2021-11-09 syoussefi@chromium.org Fix invalidation of GL_FRAMEBUFFER invalidating READ FBO
2021-11-09 syoussefi@chromium.org Add test for texture state change bug
2021-11-09 syoussefi@chromium.org Vulkan: Fix deferred clears vs invalidate
2021-11-09 jmadill@chromium.org Revert "Metal: Reintroduce GPU power preference selection code."
2021-11-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 4c6da56da96c to 7e9b8b317f16 (6 revisions)
2021-11-09 gert.wollny@collabora.com Capture/Replay: Don't force initialization of FS inout vars
2021-11-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from f1944afd4c24 to 76a46804f683 (1053 revisions)
2021-11-09 gert.wollny@collabora.com Capture/Replay: Limit the sleep time based on unfinished jobs
2021-11-09 msisov@igalia.com Reland "rename use_x11 to ozone_platform_x11"
2021-11-09 timvp@google.com Vulkan: Add flushCommandsAndEndRenderPassWithoutQueueSubmit()
2021-11-09 timvp@google.com Vulkan: Use optimalBufferCopyOffsetAlignment
2021-11-08 syoussefi@chromium.org Sync framebuffer bindings in glInvalidateFramebuffer
2021-11-08 jmadill@chromium.org infra: Switch ASAN to 64-bit on Windows.
2021-11-08 syoussefi@chromium.org Capture/Replay: Skip test of new failing tests
2021-11-08 jonahr@google.com Metal: Reintroduce GPU power preference selection code.
2021-11-08 syoussefi@chromium.org Vulkan: Fix spammy best practices message
2021-11-08 jmadill@chromium.org DEPS: Remove isolated client.
2021-11-08 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 70f3a0ff7233 to 4c6da56da96c (3 revisions)
2021-11-08 msisov@igalia.com Add GL_RGB10_EXT format into list of supported formats.

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 bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in ANGLE: https://bugs.chromium.org/p/angleproject/issues/entry
To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry

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/main/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: bsalomon@google.com
Test: Test: angle_end2end_test --gtest_filter=EGLLockSurface3Test
Change-Id: I548854459d3ec3de02f8dc212ae8829854590ccc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469717
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-11-10 05:23:26 +00:00
skia-autoroll
0adcf1c121 Roll SwiftShader from 4c6da56da96c to 82d932bdfc41 (19 revisions)
https://swiftshader.googlesource.com/SwiftShader.git/+log/4c6da56da96c..82d932bdfc41

2021-11-10 sugoi@google.com Fix Android.bp build after SPIRV-Headers update
2021-11-09 sugoi@google.com Follow-up 2: Fix Android.bp build after SPIRV-Tools update
2021-11-09 sugoi@google.com Follow-up: Fix Android.bp build after SPIRV-Tools update
2021-11-09 capn@google.com Associate inline sampler caches with instruction position
2021-11-09 capn@google.com Use the Vulkan format for OpImageWrite
2021-11-09 capn@google.com Simplify obtaining the type from a SPIR-V object <id>
2021-11-09 capn@google.com Treat sRGB formats as unsigned normalized
2021-11-09 capn@google.com Improve inverse blendConstant() readability
2021-11-09 capn@google.com Optimize clamping of constant blend factors
2021-11-09 capn@google.com Parse SPIR-V image instructions before code generation
2021-11-09 capn@google.com Check for valid SPIR-V <id>s by comparing against 0
2021-11-09 sugoi@google.com Fix Android.bp build after SPIRV-Tools update
2021-11-09 sugoi@google.com Add warning treated as error for missing case statement
2021-11-08 srisser@google.com Regres updates SHA and testlists after daily run
2021-11-08 sugoi@google.com Update SPIR-V shader instructions after SPIRV-Tools update
2021-11-08 swiftshader.regress@gmail.com Regres: Update test lists @ 4c6da56d
2021-11-08 sugoi@google.com Update SPIR-V Tools to 339d4475c
2021-11-08 sugoi@google.com Update SPIR-V Headers to 29817199b
2021-11-08 sugoi@google.com No format verification in SPIR-V headers and tools update scripts

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 bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in SwiftShader: https://bugs.chromium.org/p/swiftshader/issues/entry
To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry

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/main/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Test-Debian10-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
Tbr: bsalomon@google.com
Change-Id: Ibf64c7e1b5b6d4e14d3b6b920d6b0466841456e3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469716
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-11-10 05:08:59 +00:00
skia-autoroll
47048d2458 Roll Chromium from ffe9e7417205 to 2bf6013115a2 (490 revisions)
ffe9e74172..2bf6013115

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 bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Chromium: https://bugs.chromium.org/p/chromium/issues/entry
To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry

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/main/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: bsalomon@google.com
Change-Id: I4085fddb2ac102c150023f8f7099168ad966b412
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469606
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-11-10 04:47:34 +00:00
skia-autoroll
7fbd45f1c1 Roll Dawn from d25277844cec to c2bd88fc3253 (7 revisions)
https://dawn.googlesource.com/dawn.git/+log/d25277844cec..c2bd88fc3253

2021-11-10 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 5eb86d4ab79b to 24136212d6bc (1 revision)
2021-11-10 yunchao.he@intel.com Revise readonly depth/stencil compability between pass and bundle
2021-11-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from c9595b37aee1 to 5eb86d4ab79b (7 revisions)
2021-11-09 enga@chromium.org Support FL 11.0 adapters if they have at least Resource Binding Tier 2
2021-11-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from fa2e37497495 to c9595b37aee1 (4 revisions)
2021-11-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 5c16f77b945d to fa2e37497495 (1 revision)
2021-11-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 0e20c68092c6 to 5c16f77b945d (2 revisions)

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 sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry
To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry

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/main/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Debug-Dawn
Bug: None
Tbr: sarahmashay@google.com
Change-Id: I38672355602d3f5d28e6171fb91921c5bf0f9e9e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469718
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-11-10 04:37:59 +00:00
John Stiles
32385b7070 Report incomplete expression-statements as errors.
Previously, a dangling type or function reference would be eliminated
silently with optimizations on, or would assert when optimizations were
off.

Change-Id: Ib2e273b6f069724e8872c9cb97351b647b875a62
Bug: skia:12472
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469525
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-11-09 22:10:18 +00:00
John Stiles
ee525493ea Add test for incomplete expressions.
The ExpressionStatement currently eliminates dangling references without
reporting them as an error. This happens due to optimization; these
expressions (being meaningless) have no side effects, and so the
optimizer replaces them with Nop. When the optimizer is off, these
programs trigger an assert:

https://osscs.corp.google.com/skia/skia/+/main:src/sksl/SkSLAnalysis.cpp;l=582;drc=e7a953524787e3bd0c437ec52de4e40986689825

A followup CL will fix ExpressionStatements so that they report
incomplete expressions as an error.

Change-Id: Ica49166032e670749fc1b4e7a869fbab03364d4f
Bug: skia:12472
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469524
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-11-09 22:09:49 +00:00
John Stiles
3b6e07098b Enable constant-expression folding at all times.
In some contexts, we rely on constant expressions to fold in order for
SkSL to work properly. (e.g. an array size is allowed to be any
constant-expression in GLSL, but the compiler really needs to know the
actual size). Previously, turning off optimization would break several
tests. Now, constant-expression folding always occurs even when the
optimizer is disabled.

Note that disabling the optimizer isn't an end-user option, so this
only affects internal usage.

Change-Id: I106ecb7e5bff3f7a8235cdccf0a7a60b48a97e2e
Bug: skia:12472
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469520
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-11-09 21:47:25 +00:00
Brian Osman
a45c93c505 Add a color-spin control to Viewer
This cycles the primaries, just like SkColorSpace::makeColorSpin.
Helpful for debugging more exotic color space issues.

Change-Id: I3434c7a9f24642f13be0ac3513599a15247d1f6f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469360
Auto-Submit: Brian Osman <brianosman@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-11-09 21:15:04 +00:00
Brian Osman
f893df91d6 Clamp lighting dot product in paint_alpha_normals_rt
Fixes inconsistent results in other color types/spaces, where the output
can be negative.

Change-Id: I8a346cf7bb02cb298c11d658948c117d74b6ddaa
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469359
Auto-Submit: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-11-09 21:13:10 +00:00
Dominik Röttsches
612c73329b COLRv1 GM test for foreground color
Updated COLRv1 samples font file from
https://github.com/googlefonts/color-fonts/pull/80

Bug: skia:12576
Cq-Include-Trybots: luci.skia.skia.primary:Test-Android-Clang-GalaxyS20-GPU-MaliG77-arm64-Release-All-Android_NativeFonts,Test-Debian10-Clang-GCE-CPU-AVX2-x86_64-Debug-All-NativeFonts
Change-Id: I18164fda87ffc3a2a05749f55ca61813cac14b41
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468236
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: Dominik Röttsches <drott@chromium.org>
2021-11-09 20:52:56 +00:00
Herb Derby
add2c39dce use sk_sp<SkStrike> instead of SkStrikeSpec
This CL focuses on removing the SkStrikeSpec from the GlyphVector.
Now the GlyphVector can use an SkStrike directly. This CL
is mostly a bunch of tricky plumbing.

Change-Id: I4eb8ccfc44d9e8b7f35578bf754c188a7fd55596
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469176
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-11-09 18:54:16 +00:00
Chris Dalton
58d633b63f Revert "[MiddleOutPolygonTriangulator] Convert pushVertex(p0) to close()"
This reverts commit 2ed7729180.

Reason for revert: Didn't help, introduced small regressions.

Original change's description:
> [MiddleOutPolygonTriangulator] Convert pushVertex(p0) to close()
>
> This is the pre-iterator behavior of MiddleOutPolygonTriangulator.
> It's slower, but may lead to better triangulations.
> We may or may not keep it, depending on Perf's opinion.
>
> Bug: skia:12620
> Change-Id: I46f39b551b32af4eebfe8221cbb48a4332db83a8
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468096
> Reviewed-by: Michael Ludwig <michaelludwig@google.com>
> Commit-Queue: Chris Dalton <csmartdalton@google.com>

Bug: skia:12620
Change-Id: I58e7cc066540c594144f1e4d0cc1646051441af4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469230
Auto-Submit: Chris Dalton <csmartdalton@google.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2021-11-09 18:37:32 +00:00
John Stiles
6a5f772ea6 Fix crash with the inliner when optimizing built-in modules.
We had never set up the ModifiersPool here, so if the inliner tries to
make a scratch variable, it ends up accessing a null ModifiersPool and
crashing. I discovered this error by disabling optimization during the
initial loadModule call (during an unrelated experiment).

Change-Id: Ifa3e0007dc1dea02745d55a544b6ddd7b5a7c6de
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469517
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-11-09 18:16:03 +00:00
Kevin Lubick
d6af8bf966 [infra] Make jobs use Gold's public hashes
Change-Id: Ia5da00913d0b96e9edc47f8b2274bd26c35c251c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469457
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
2021-11-09 17:50:55 +00:00
John Stiles
183f37d16a Add trace opcodes for function entry/exit.
This enables stepping over function calls automatically.

Change-Id: Ie15ed745377d851cb7752f651b573efa2cc8195f
Bug: skia:12614
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469077
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-11-09 16:35:02 +00:00
Leon Scroggins III
540eb372fc Remove unused variable 'heapIndex'
Bug: NA

Though we set this variable, we never use its value. This causes a
warning in Android.

Change-Id: I84492fd97e8c6f23db7bf51c116d227551ae7a94
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469358
Commit-Queue: Leon Scroggins <scroggo@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Auto-Submit: Leon Scroggins <scroggo@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2021-11-09 16:32:14 +00:00
John Stiles
efd828091d Emit trace_line ops to indicate for-statement next/test.
Previously, the for statement's "increment/test" expressions were
executed without moving the trace-line back up to the for statement.
When stepping through code, we will now explicitly step to the next/test
line on each loop iteration.

Change-Id: I5d9f005a42150670cec77218323cf932ee1cbdb0
Bug: skia:12614
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469180
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-11-09 16:01:45 +00:00
John Stiles
70ae43148d Implement trace_var opcode.
This writes an entry to the trace buffer every time a slot value is
changed.

Change-Id: Iac3912be71ad654f70a7158e306e0643086c6cb0
Bug: skia:12614
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469179
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-11-09 15:24:00 +00:00
Jim Van Verth
9b353b90c6 [graphite] Add commands to CommandBuffer from Tasks
Bug: skia:12466
Change-Id: I1e92dcf66c117ca351cebf20722524672c88e5cd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469178
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-11-09 15:10:22 +00:00
Kevin Lubick
b9f18641f8 Add Bazel folks as owners to BUILD.bazel files
Change-Id: I80d3706984da46deb34b886babab316ad253951e
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469356
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2021-11-09 14:24:54 +00:00
Brian Osman
1b61d866a6 Reland "Add ConvertPixels versions of PremulAlphaRoundTrip"
This is a reland of b61804e94c

Original change's description:
> Add ConvertPixels versions of PremulAlphaRoundTrip
>
> Prior to the force_highp trick, the GrConvertPixels version failed, just
> like the GPU would do if we disabled the canvas2D fast path. With the
> highp trick, all tests pass.
>
> Bug: skia:12592
> Change-Id: I63ad2fd3b67863b6a736316e7c7b3b9bd2ee8970
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/467516
> Commit-Queue: Brian Osman <brianosman@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>

Bug: skia:12592
Change-Id: I4c83c8d20959ab13cc493748a22fff5133706a77
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468458
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-11-09 14:03:58 +00:00
skia-autoroll
fa26a656cf Roll Dawn from eb9339bdf38f to d25277844cec (4 revisions)
https://dawn.googlesource.com/dawn.git/+log/eb9339bdf38f..d25277844cec

2021-11-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 017161701b7d to 0e20c68092c6 (3 revisions)
2021-11-08 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 27a7002511d6 to 017161701b7d (3 revisions)
2021-11-08 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 1f42f6bd1e32 to 27a7002511d6 (1 revision)
2021-11-08 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from ee8e8a68c5a9 to 1f42f6bd1e32 (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/dawn-skia-autoroll
Please CC sarahmashay@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Dawn: https://bugs.chromium.org/p/dawn/issues/entry
To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry

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/main/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Debug-Dawn
Bug: None
Tbr: sarahmashay@google.com
Change-Id: I65b4f5eb02cfcc0d2c2e53bd51f25a9870a211af
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469316
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-11-09 13:22:58 +00:00
Kevin Lubick
1f8c31b101 [infra] Add initial Bazel rules and files
These rules can be used to build our GMs on WASM+WebGL and
libskia.a with just the CPU backend (and most other features
turned off).

This can be done with the following commands:
  - bazel build //modules/canvaskit:gm-bindings-wasm --gpu_backend=gl_backend --with_gl_standard=webgl_standard
  - bazel build :skia-core --config clang

This pivots slightly from http://review.skia.org/463517
by using config_settings [1] instead of platforms for
the optional features that we control. This pivot was
suggested in [2]

We have BUILD.bazel files in many of the subdirectories
that specify filegroups for the appropriate files. In
an effort to make //BUILD.bazel more readable, it is
the responsibility of these subfolders to deal with
conditionally including certain .h or .cpp files.
This is done using select statements and config_settings
or platform constraints as necessary.

For example, src/gpu/BUILD.bazel will different private
filegroups for each of the supported gpu backends [3]
and a more-visible filegroup called "srcs" that has
the right selection of the private files to be used
for compilation.

An effort has been made to avoid using glob() in our
BUILD.bazel files. These file lists were made by using
`ls -1` and some regex to add in quotes. We might want
to make a helper script to assist with that, if necessary.

To specify which options we have, the settings in
//bazel/common_config_settings/BUILD.bazel have been
redesigned. They make use of a macro `string_flag_with_values`
that removes the boilerplate. Patchset 36 shows what the
file looks like w/o the macro.

The top level BUILD.bazel file will still need to use
some logic to handle defines, because local_defines is
a list of strings, not a list of labels [4].

Suggested Review Order:
  - WORKSPACE.bazel to see the new dependencies on the
    emsdk toolchain and bazel_skylib
  - bazel/common_config_settings/* to see the few settings
    defined (we have more to define, see BUILD.gn and
    //gn/skia.gni for ideas)
  - BUILD.bazel to see the "skia-core" cc_library rule.
    See also "gms" and "tests"
  - modules/canvaskit/BUILD.bazel to see the use of
    the emscripten "wasm_cc_binary" rule, which depends
    on the "skia-core", "gms", and "tests" rule. Note that
    it only builds some of the gms as a proof of concept.
  - The other BUILD.bazel files. Some of these are not
    platform or feature dependent (e.g. pathops). Others
    are (e.g. gpu).
  - All other files.

[1] https://docs.bazel.build/versions/4.2.1/skylark/config.html#user-defined-build-settings
[2] https://github.com/emscripten-core/emsdk/pull/920
[3] In this CL, that's just the webgl one.
[4] https://docs.bazel.build/versions/main/be/c-cpp.html#cc_library.local_defines

Change-Id: Ieecf9c106d5e3a6ae97d13d66be06b4b3c207089
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/458637
Reviewed-by: Ben Wagner <bungeman@google.com>
Reviewed-by: Leandro Lovisolo <lovisolo@google.com>
Owners-Override: Kevin Lubick <kjlubick@google.com>
2021-11-09 12:32:25 +00:00
skia-autoroll
badc896b18 Roll Chromium from f3e2d73a87ed to ffe9e7417205 (463 revisions)
f3e2d73a87..ffe9e74172

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 bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Chromium: https://bugs.chromium.org/p/chromium/issues/entry
To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry

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/main/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: bsalomon@google.com
Change-Id: I9964523e524b73a4deab7a216b36cd828c8e792d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469234
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-11-09 10:17:01 +00:00
Chris Dalton
a7623433da Improve the fan point for wedges
When paths closed themselves explicitly, we were double counting the
start point. This was technically fine, since any fan point in
(-Inf, +Inf) will work, but this is a common enough case that it's
worth it to try and place the fan point closer to center.

Bug: skia:12524
Change-Id: Id94be4f2f28e4c0d287439db4ed83f389b163d57
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469096
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-11-09 01:48:34 +00:00
John Stiles
70db6e4443 Use writeToSlot to update fSlots.
This gives us a natural foothold to write variable-change trace ops.

Change-Id: I0616ed374a3cf63ad33b6f14696acefde0741384
Bug: skia:12614
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468826
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-11-08 22:19:15 +00:00
John Stiles
890235f3eb Add NumberKind to Slot struct.
It is useful to know the type of data in a slot (float or int) if we
plan to show it in human-readable form.

Change-Id: I4befdfcca6826792cd09b6a06a71cfd639d55822
Bug: skia:12614
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469076
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-11-08 22:18:58 +00:00
John Stiles
edc7b47cbc Update fSlots to store its data in a Slot struct.
Previously, the fSlots array only carried skvm::Val data. Using a struct
will allow fSlots to carry additional information. In particular, it
will be useful to know the type of data in a slot (float or int) if we
plan to show it in human-readable form.

Change-Id: I6270bfc587045736f647ae744cfa36a2e4b5b65f
Bug: skia:12614
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469059
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-11-08 22:14:08 +00:00
Ben Wagner
2660bfd2d8 Fix new/delete mismatch in SkBlockAllocatorTest
Resolves an issue found with mismatched-new-delete in newer GCC.

Change-Id: Ifa7f133a16699d7f6a84f63b07ef4d5fde55dd32
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468822
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2021-11-08 21:11:04 +00:00
Lei Zhang
065c5d9408 Remove deprecated fType field in StructureElementNode.
It was added for Chromium, and Chromium has switched to using
fTypeString instead.

Change-Id: I8cd8ae00b0c3abf3691ce14837afbe3be939538e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/316209
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-11-08 20:32:27 +00:00
Herb Derby
21f7a9a757 remove strikeToSourceRatio from SkStrikeSpec
Change-Id: Ic8b9753f87ec3170a5dc98c19020929ea805797c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469058
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-11-08 18:20:01 +00:00
Ravi Mistry
d0e23588e5 Update versions of non-generated SKPs in RecreateSKPs bot
Cq-Include-Trybots: luci.skia.skia.primary:Housekeeper-Nightly-RecreateSKPs_DryRun
Bug: skia:12623
Change-Id: I71e142cccdfbc016ed6d06bb5aaedb7a265fdb0d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/467297
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2021-11-08 18:08:19 +00:00
Nils
a1705e26a8 Typo: "then then" -> "then"
This is an imported pull request from
https://github.com/google/skia/pull/89

GitOrigin-RevId: c3ec59f33347ba9b644583bf81df663d51238ccf
Change-Id: Ie7bb42766f652a722de966d6bc31be9ae2ef8713
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468796
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2021-11-08 17:06:28 +00:00
Chris Dalton
e05285a8dd Don't use the atlas for MSAA convex paths
As long as we don't have DMSAA, convex paths should be drawn directly
as opposed to through an atlas.

Bug: skia:12524
Change-Id: Ib17ce390cbdb7109ecdee4b665d21a8345eb3773
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469036
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-11-08 17:01:44 +00:00
Brian Osman
864f71b3ac Remove unused GrFPArgs::fInputColorIsOpaque
Change-Id: I0bd34550c762e5d0f88cf7e3e44cbf38d2a8a7ba
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469057
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-11-08 16:51:59 +00:00
Eric Boren
4a41c9401e [cq] Replace Win10 HD7770 D3D tryjob with QuadroP400 on the CQ
Change-Id: I814a42a1367ce0ebe1d065192bd2c7d8596bf77d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469056
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2021-11-08 16:34:56 +00:00
Brian Osman
529d3473bf Move alpha modulation into paint conversion (Step 2)
With paint conversion changed, this CL cleans up several SkShader
classes, based on the fact that input alpha will always be opaque.

Bug: skia:11942
Change-Id: I492a87bf1702f1553d20f3d05dcaf023069ae905
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/468456
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-11-08 15:57:04 +00:00