Commit Graph

58488 Commits

Author SHA1 Message Date
Jason Simmons
ddbf93159f Move Run per-glyph data into an object held in a shared_ptr
This will reduce memcpy overhead when runs are copied into a paragraph
or when paragraph cache entries are read or written

Change-Id: Id81725f3d8fc70daa17d154093ae7bc8b519118c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483022
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Jason Simmons <jsimmons@google.com>
2021-12-13 22:24:30 +00:00
John Stiles
0745d19ae3 Hide function return values after a step.
Previously, return values like `[func].result` would stick around in the
Variables table indefinitely. This felt very counterintuitive. Now they
only appear for one step, then vanish.

Change-Id: Iedfc7d2ddf136111005b26aaefb380ffc6281d05
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483605
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-12-13 22:14:35 +00:00
Michael Ludwig
fdae1b765f [graphite] Clear depth/stencil attachments to 0
Cq-Include-Trybots: luci.skia.skia.primary:Test-Mac11-Clang-MacMini9.1-GPU-AppleM1-arm64-Release-All-Graphite,Test-Mac11-Clang-MacMini9.1-GPU-AppleM1-arm64-Debug-All-ASAN_Graphite,Build-Mac-Clang-arm64-Release-iOS_Graphite,Build-Mac-Clang-arm64-Release-Graphite,Build-Mac-Clang-arm64-Debug-iOS_Graphite,Build-Mac-Clang-arm64-Debug-Graphite_NoGpu,Build-Mac-Clang-arm64-Debug-Graphite,Build-Mac-Clang-arm64-Debug-ASAN_Graphite
Bug: skia:12700, skia:12703
Change-Id: I0d32b2542bf779c2e2229ad3f56eca2129ff3b8c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483521
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-12-13 21:55:48 +00:00
Michael Ludwig
3ad6e531c3 [graphite] Fix instance vs. non-instanced detection
Previously, non-instanced draws that needed a base vertex because of
dynamic state would cause useNonInstancedDraws to be false, and then
the recorded draw calls are wrong.

This also tweaks the logic to be useInstanceDraws instead since the
layers of negation were getting annoying to reason through.

Cq-Include-Trybots: luci.skia.skia.primary:Test-Mac11-Clang-MacMini9.1-GPU-AppleM1-arm64-Release-All-Graphite,Test-Mac11-Clang-MacMini9.1-GPU-AppleM1-arm64-Debug-All-ASAN_Graphite,Build-Mac-Clang-arm64-Release-iOS_Graphite,Build-Mac-Clang-arm64-Release-Graphite,Build-Mac-Clang-arm64-Debug-iOS_Graphite,Build-Mac-Clang-arm64-Debug-Graphite_NoGpu,Build-Mac-Clang-arm64-Debug-Graphite,Build-Mac-Clang-arm64-Debug-ASAN_Graphite
Bug: skia:12703
Change-Id: I370d06528055de5412e29710906ce1a76e1bd7c2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483520
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2021-12-13 21:30:58 +00:00
Michael Ludwig
64ed6fdc87 [graphite] Embed SkPathFillType into Renderer definitions
The fill types require different stencil settings to implement, but
the stencil settings are fixed for a RenderStep. This means that each
fill type requires its own Renderer.

Cq-Include-Trybots: luci.skia.skia.primary:Test-Mac11-Clang-MacMini9.1-GPU-AppleM1-arm64-Release-All-Graphite,Test-Mac11-Clang-MacMini9.1-GPU-AppleM1-arm64-Debug-All-ASAN_Graphite,Build-Mac-Clang-arm64-Release-iOS_Graphite,Build-Mac-Clang-arm64-Release-Graphite,Build-Mac-Clang-arm64-Debug-iOS_Graphite,Build-Mac-Clang-arm64-Debug-Graphite_NoGpu,Build-Mac-Clang-arm64-Debug-Graphite,Build-Mac-Clang-arm64-Debug-ASAN_Graphite
Bug: skia:12703
Change-Id: I9a8e3546555308835c2a11d7e2b54f36470dc297
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483518
Auto-Submit: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2021-12-13 21:19:46 +00:00
John Stiles
49cb6d7668 Add a Variables pane to the SkSL debugger.
The currently-active stack frame is always shown. Values which were
modified during the last step action are highlighted.

http://screen/4E4BLXYJsDR5bhk

Change-Id: I521d92fa6c1eabd64aaeeb188c71f04a79f827f5
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483602
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-13 20:29:26 +00:00
John Stiles
0385de0f88 Add helper method to get the human-readable value of a slot.
We already had this logic in SkVMDebugTrace::dump; it just needed to be
factored out so that it could be accessed directly.

Change-Id: Ib497b82a7722b8ac2285de74f1937379c2f9a51b
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483600
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-12-13 19:57:28 +00:00
Jim Van Verth
c46b4d0a48 Add divide-by-zero check to GrGenerateDistanceFieldFromPath
Bug: oss-fuzz:32768
Change-Id: I9273ba1242a0f61dc5b26b2651400b4b46dd3992
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483596
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-12-13 19:54:28 +00:00
John Stiles
9247feb52c Report slot updates using a dirty mask.
By tracking slot writes using a dirty mask, and reporting these in the
VariableData, we will be able to highlight assigned-to variables in the
debugger.

Change-Id: I93a767095c9c1b6dedc55a08424649f83aa1c960
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483598
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-13 19:26:43 +00:00
Jim Van Verth
e4bccab4ac Fix divide-by-zero in AAConvexTessellator.
Bug: oss-fuzz:32385
Change-Id: I048e5a55430c0c968b858b0ac25d077a35332e02
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483519
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-12-13 19:10:34 +00:00
Herb Derby
5d6e51dbec remove SK_EXPERIMENTAL_ADD_ATLAS_PADDING from Skia
As of the following Chromium CL the flag
SK_EXPERIMENTAL_ADD_ATLAS_PADDING is no longer used.

https://chromium-review.googlesource.com/c/chromium/src/+/3332838

Change-Id: I026b736dc26268fbe888fd3a8b56d056f4127e36
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483597
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-13 18:52:03 +00:00
Herb Derby
8dc9a337ab rename GrTextBlobCache to GrTextBlobRedrawCoordinator
Change-Id: Ib1ea2936f7a9431bc62c04b1931cf6da2c213b36
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483496
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-13 17:38:00 +00:00
John Stiles
fbb743377a Add method to get the suffix for a trace's slot.
We already had this logic in SkVMDebugTrace::dump; it just needed to be
factored out so that it could be accessed directly.

Change-Id: Idd6c92d23ab4dddc60fdc3c7b1693a0d89b1c992
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483517
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-12-13 16:54:33 +00:00
John Stiles
5d3060ed94 Add support for stepping out from a function.
Stepping out is extremely similar to stepping-over, so this was mostly
working already.

Change-Id: Ib1c1ba96b45a732500e72b6da4cbfe41a1f75307
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483196
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-12-13 16:43:49 +00:00
John Stiles
a26ba3e51b Improve the debugger code view.
The raw text has been replaced with a proper table. Stepping through
code now scrolls properly to focus on the current line. The ASCII "->"
arrow has been replaced by a focus highlight. The top controls no longer
scroll away when browsing code.

http://screen/BnTa3thYzUgTTdG

Change-Id: Ieaa3a479099bbd09d9ba2cb5552befdd5307f9c5
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483156
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-12-13 16:43:23 +00:00
John Stiles
00b3fcccdf Create Debugger slide for Viewer.
This is a very rough first draft which provides the bare minimum. Shader
source is dumped to the window as static text, along with an arrow
tracking the current trace line. Two buttons allow for single-step and
step-over. There aren't yet any GUI affordances for the stack or
variables.

http://screen/44WAnxchjy8MPjM

Change-Id: Ifad4a146b54d334113b02132eec2238af4fd8580
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/481681
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-13 16:28:06 +00:00
skia-autoroll
507884bf3d Roll ANGLE from 3be551d7c2c5 to a1b9eb68e417 (18 revisions)
3be551d7c2..a1b9eb68e4

2021-12-11 gman@chromium.org Replace IOSurfaceSurfaceEAGL.mm table with less strict padding
2021-12-11 kpiddington@apple.com Metal: Fix M1 and iOS synchronization for readPixels
2021-12-11 gman@chromium.org Metal: Add maximum render target size validation
2021-12-11 gman@chromium.org Add early out validation in drawArraysCommon
2021-12-11 gman@chromium.org Metal: Refactor restartRange cache
2021-12-11 gman@chromium.org Metal: Fix Instanced Draw feature support on Simulator
2021-12-11 gman@chromium.org Metal: Refactors from Webkit
2021-12-10 gman@chromium.org Metal: Merge changes to mtlPixelFormatTable
2021-12-10 lubosz.sarnecki@collabora.com Reland "system_utils: Add memory protection functionality."
2021-12-10 jmadill@chromium.org Trace Tests: Ensure zillow runs on SwiftShader.
2021-12-10 abdolrashidi@google.com Update the arg types for glMultiDraw*IndirectEXT()
2021-12-10 sugoi@google.com Add debug info when loading EGL entry points fails
2021-12-10 penghuang@chromium.org Enable GL_ANGLE_texture_usage extension
2021-12-10 penghuang@chromium.org Use STL container for vulkan memory allocator
2021-12-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from 38603b300bce to 267fa481ccad (8 revisions)
2021-12-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 4625f84e8d56 to 4c62980da8c1 (6 revisions)
2021-12-10 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from e1fa86b1827a to 6214b401e0c5 (1064 revisions)
2021-12-10 polynomialspace@gmail.com fix typo: 'choromium' -> 'Chromium'

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 bungeman@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: bungeman@google.com
Test: Test: angle_unittests --gtest_filter="SystemUtils.PageFaultHandler*"
Change-Id: I005ca3156433898e15c5a1189f08868e38ce054b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483377
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 05:24:55 +00:00
skia-autoroll
a99933139d Roll Chromium from ef37f0f232c3 to 97fa68dda69c (498 revisions)
ef37f0f232..97fa68dda6

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 bungeman@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: bungeman@google.com
Change-Id: I4c7e622bfad8010bbd9465e9ce0b05f11240e6f6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483378
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 05:00:25 +00:00
skia-autoroll
19f7b34f4b Roll Dawn from 1f25ea94bbb7 to ffb0024a8970 (7 revisions)
https://dawn.googlesource.com/dawn.git/+log/1f25ea94bbb7..ffb0024a8970

2021-12-13 jie.a.chen@intel.com Support NV12 via ExternalImageDescriptorDmaBuf on CROS
2021-12-11 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 56aee5d6407f to a1b9eb68e417 (8 revisions)
2021-12-10 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from ac9b2703e8fa to 56aee5d6407f (9 revisions)
2021-12-10 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 30d55fabc91f to 5923803f7e84 (1 revision)
2021-12-10 cwallez@chromium.org Vulkan: make PNextChainBuilder require pNext==nullptr
2021-12-10 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 0fe30b52a5c9 to 30d55fabc91f (18 revisions)
2021-12-10 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 663831aa676c to ac9b2703e8fa (2 revisions)

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from 0fe30b52a5c9 to 5923803f7e84

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 cwallez@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: cwallez@google.com
Change-Id: I45bb2fbb41e78a900fc66532f9b8d83f191e7e0c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483376
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-13 04:38:32 +00:00
skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com
87025fe5b3 Update SKP version
Automatic commit by the RecreateSKPs bot.

Change-Id: I558f07c9ee81d7179764235847754be346812b2d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483267
Commit-Queue: skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
Bot-Commit: skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
2021-12-12 08:20:26 +00:00
skia-autoroll
d393ab3972 Roll SK Tool from a3fbba5857f1 to 6380ad5ed012
https://skia.googlesource.com/buildbot.git/+log/a3fbba5857f1..6380ad5ed012

2021-12-12 skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com Update CIPD Packages

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

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

Tbr: erikrose@google.com
Change-Id: I8e71fd2675394cec5c0c97311b068199afbdcff5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/483257
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-12 05:54:55 +00:00
Jim Van Verth
454c04e8f3 [graphite] Add shader error handling
Change-Id: I21743290128140bef729eef967e841a65f9fdc67
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482702
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-12-11 00:18:22 +00:00
Jim Van Verth
db9f95c888 Move ShaderUtils out of Ganesh.
This will allow us to use ShaderUtils in both Ganesh and Graphite.

Change-Id: I78e34c4eb969a0d827c459d7fb945d17fdc22efa
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482696
Reviewed-by: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-12-10 23:10:25 +00:00
John Stiles
5d5f24e814 Move SkVMDebugTrace into src/sksl/tracing.
Change-Id: Id4fc455f0eb23aa8d9b6f5474be7f6eba71c48de
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482698
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-12-10 21:58:01 +00:00
John Stiles
f3b4617828 Create SkVMDebugTrace player class.
This class is responsible for interpreting a debug trace and allowing it
to be stepped through, like a debugger. It tracks the current line
number, call stack, slot values, and associates slots with stack frames.
It supports stepping forward or stepping over (i.e., stepping to the
next line in the current function, hiding function calls).

Change-Id: I2b7d90c3b38b0006bebdfbf65a7bf678d5227d56
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482460
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-12-10 21:57:58 +00:00
Herb Derby
c279e7640b add bilerp atlas support flag
Move the compile-time flag SK_EXPERIMENTAL_ADD_ATLAS_PADDING,
to a runtime flag in GrContextOptions.

Bug: chromium:1275890

Change-Id: I7e051cd4834ac44958b1431976535519e8bdaa3e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482416
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-10 20:33:57 +00:00
Herb Derby
0f2390f7fb move SkRemoteGlyphCache.h to private
Chromium has been using the remote glyph cache for a few years now.
It's time to give it a proper home.

This is an intermediate CL. The old .h file includes the new .h file.
After I change the include paths in Chromium, I will delete the old
file.

Change-Id: Iaf00c46aa0698326c0bdec9a0eed218bcc3e334e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482700
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-10 20:20:56 +00:00
John Stiles
1786647583 Improve debug trace generation speed by clipping the paint.
When generating a debug trace, we disable most optimizations, pessimize
the SkVM code with many additional instructions, and run the interpreter
instead of the SkVM JIT. Additionally, while under development, viewer
is generally compiled in -O0. All of these changes made it painfully
slow to generate the debug trace of a complex shader, even though we
only care about tracing a single pixel of the paint.

Now, when taking a debug trace, we clip the paint to a small 4x4 area
surrounding the trace coordinate for a single frame. This makes debug
traces run very quickly, even on a modest laptop CPU.

Change-Id: Ibcadc20a8d83a3a241e05408b8af31d61cf03d4c
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482701
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-10 20:13:00 +00:00
Herb Derby
4d35c0d31d relocate GrTextBlob creation to GrTextBlobCache
Move the GrTextBlob creation code to GrTextBlobCache allowing
more cache calls to be private.

Change-Id: I9ecb732c066ef7dadf8bc478a8b4d3dea8c292a9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482697
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-10 18:56:35 +00:00
John Stiles
b1a97caf71 Revert "Trace function return values after function-exit."
This reverts commit 85cc1bece7.

Reason for revert: ends up not being useful after all

Original change's description:
> Trace function return values after function-exit.
>
> This will allow function return values to be easily seen when stepping
> "over." This has the unexpected side benefit of generating slightly
> fewer ops when a function has unoptimizable conditional returns.
>
> Change-Id: I48d23de635d3caaddff91aa595593d0371dfcdcb
> Bug: skia:12708
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/481076
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>
> Auto-Submit: John Stiles <johnstiles@google.com>

Bug: skia:12708
Change-Id: I61ebb175b60d2060f6ad21b170238b37557b80be
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482458
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-12-10 18:06:04 +00:00
Brian Osman
f693b20c37 Add gdbserver instructions to site docs
Change-Id: I13ba477d5b390a0fc03cd4960b6a19bcaa4266d7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482699
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
2021-12-10 16:41:09 +00:00
Ben Wagner
15f186d277 GrMemoryPool always standard_layout for offsetof
GrMemoryPool in debug has extra fields and so wants to make use of
offsetof. The offsetof can only be taken on standard layout objects.
However, in debug std::unique_ptr may not be standard layout, which
makes SkAutoTArray not standard layout, which makes SkTHashTable not
standard layout, which makes SkTHashSet not standard layout, which makes
GrMemoryPool not standard layout, producing a compile error.

Since this is debug only, move the debug only fields behind a pointer
(which unfortunately cannot be a std::unique_ptr, since it may not be
standard layout). This allows building with recent libc++ headers and
clang.

Change-Id: Id9d312d7939808399d0796428de218d30263c26f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482004
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2021-12-10 16:11:35 +00:00
Michael Ludwig
b05732e102 Rewind farther on topology intersect mismatch
Also fixes recursion end point update in recursive_edge_intersect, which
was causing us to search in the wrong area of the lines and falsely
report no intersection when there should have been one (which is then
detected by the topology check in intersectEdgePair() and more less
accurately corrected for).

Bug: chromium:1245359
Change-Id: I1d21c934a23c9b99c3767849ee19bc2f6c551d3f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482456
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2021-12-10 15:46:53 +00:00
Heather Miller
e3c1c4b589 Update Skia milestone to 99
Change-Id: Ifc671649da20706dbce9480dc60b4184a0bb8bf7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482636
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Heather Miller <hcm@google.com>
2021-12-10 14:47:56 +00:00
John Stiles
83b5237b53 Fix assertion when debug-tracing a void-return function.
The debug-slot code didn't expect to encounter a void type.

Change-Id: Ied452b51e1cf90a0c0bc24770f82e711105b8e82
Bug: skia:12708
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482461
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-12-10 14:39:05 +00:00
John Stiles
c962042ed2 Add field to SkVMSlotInfo indicating function return values.
Function return values exist at the boundary between stack frames and
will need slightly special treatment by the debugger.

Change-Id: I017b5713919f507074f072d040332325307c2e81
Bug: skia:12666
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482459
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-10 14:10:57 +00:00
Kevin Lubick
766a605380 [infra] Fix pubsub notification for autobuild
Change-Id: I08743486b7d9f06ef803c5c52a50f590b3bddf53
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482616
Reviewed-by: Eric Boren <borenet@google.com>
2021-12-10 14:07:08 +00:00
Brian Osman
351148ff38 Create SkVMCallbacks, to bundle the child-sampling routines
I'm about to add more callbacks, and the collection of std::function was
getting unmaintainable. This mirrors the pipeline-stage generator, and
also is structured to share more code among the different runtime effect
objects.

Change-Id: Ib82042781051471a6743401db45ce24540bfa253
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/481684
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-10 13:53:22 +00:00
skia-autoroll
53f3fda283 Roll ANGLE from 0e291f60ccbf to 3be551d7c2c5 (6 revisions)
0e291f60cc..3be551d7c2

2021-12-10 hailinzhang@google.com fix directUpdate buffer pointer issue.
2021-12-09 jmadill@chromium.org Revert "Reland "system_utils: Add memory protection functionality.""
2021-12-09 gman@chromium.org Metal: Fix Intel backend fails with tall texture
2021-12-09 cclao@google.com Vulkan: Append the actual buffer size when binding's size is 0
2021-12-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from a4232c15e287 to 4625f84e8d56 (5 revisions)
2021-12-09 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from bc087f672f16 to 38603b300bce (6 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 jmbetancourt@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: jmbetancourt@google.com
Change-Id: Iaa0a820093d999d59a62c2e53b9f004888afb777
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482518
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-10 05:33:55 +00:00
skia-autoroll
3b73499eaf Roll Chromium from 4fa82a541d87 to ef37f0f232c3 (495 revisions)
4fa82a541d..ef37f0f232

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 jmbetancourt@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: jmbetancourt@google.com
Change-Id: I480d7a3dee0a4f64e15c9c1aac61b7b6147c38a9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482516
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-10 04:51:57 +00:00
skia-autoroll
d6509f572b Roll Dawn from 264f239259c5 to 1f25ea94bbb7 (9 revisions)
https://dawn.googlesource.com/dawn.git/+log/264f239259c5..1f25ea94bbb7

2021-12-10 jiawei.shao@intel.com dawn_wire: Directly use the data in deserialized buffer when possible
2021-12-10 enga@chromium.org Enable dynamic storage buffers
2021-12-10 junwei.fu@intel.com Replace hardcode functions in templates
2021-12-09 yunchao.he@intel.com Add validations for depth/stencil aspect requirement for DepthStencilState
2021-12-09 yunchao.he@intel.com Implement readonly depth/stencil attachment on Vulkan
2021-12-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 0e291f60ccbf to 663831aa676c (5 revisions)
2021-12-09 enga@chromium.org Add a build target for a webgpu_dawn library
2021-12-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from a8c202b8e779 to 0fe30b52a5c9 (1 revision)
2021-12-09 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll ANGLE from 16ce5226e896 to 0e291f60ccbf (3 revisions)

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from a8c202b8e779 to 0fe30b52a5c9

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 cwallez@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: cwallez@google.com
Change-Id: I58343c8f513e51636e562c1e2944cdcddb5b8587
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482517
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-12-10 04:44:57 +00:00
Herb Derby
3317b1b23e consolidate processing for sub runs multiple formats
Change-Id: Ief27a4a8051485bed20e1a5312457e778cb28171
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482007
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-09 22:45:47 +00:00
Lei Zhang
e4f148f09f Remove unneeded include from SkFloatingPoint.h.
The _POSIX_VERSION check was initially added in
https://skia.googlesource.com/skia/+/d3fbd34099, and its usage was
removed in https://skia.googlesource.com/skia/+/d7dc76f7e9. Since that's
long gone, remove the include associated with that. Then do IWYU to fix
the build.

Change-Id: Ic256d64a2e02bd8ada03513bb04b0e733576c474
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482256
Auto-Submit: Lei Zhang <thestig@chromium.org>
Reviewed-by: Ben Wagner <bungeman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2021-12-09 22:45:23 +00:00
Brian Salomon
eb6851ab51 Make simple coord/size getters on Sk[I]Rect constexpr
Bug: skia:12720
Change-Id: I349a3dd8ae58eefcadbace7847798fbe57227a41
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482008
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-12-09 22:17:30 +00:00
Robert Phillips
a964a72174 [graphite] Reenable linear gradient shading
Bug: skia:12701
Change-Id: I51bfad4ff61f2ab32753e532eb5b6ee46d765303
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/481737
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2021-12-09 21:16:00 +00:00
Arman Uguray
b58bab1fed [skslc] Support HLSL output
- skslc can now generate HLSL using spirv-cross if invokved with an output
file with the ".hlsl" extension
- The SkSL::SPIRVtoHLSL function used to be conditionally compiled based
on the SK_USE_DIRECT3D define, which gates D3D support for the entire
gpu backend. This function is now conditionally compiled using a new,
more narrowly scoped define, which is always enabled when building
skslc.

Bug: skia:12691
Test: Run:
Change-Id: I6967c26ab28954ec09e1c62513187c8986135290
      1. ./skslc ../../resources/sksl/spirv/Ossfuzz35916.sksl TEST.hlsl
      2. ./dxc -T ps_6_7 TEST.hlsl
      Ensure that 1 runs without any errors and 2 does not detect any
      issues in the hlsl.
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482257
Auto-Submit: Arman Uguray <armansito@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-09 21:07:30 +00:00
Julia Lavrova
57043197c1 Merging the logic for binary and compare
I was wrong and @johnstiles was right. It does work...

Change-Id: Id51d7732a44db996e078337a9b8e4136353ac922
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482009
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-12-09 21:06:25 +00:00
Leon Scroggins III
30d5eea3dc Treat AHARDWAREBUFFER_FORMAT_R8_UNORM as kAlpha_8_SkColorType
Bug: b/193170859
Bug: b/209497983

Change-Id: I51d38cfcd89623e618e1fa34a1f87c1dd777b7f5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/479737
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2021-12-09 20:52:31 +00:00
Kevin Lubick
1a81d672a4 [infra] Have jsfiddle be autodeployed from Bazel, not from Webpack
Change-Id: I91126fcde291a4719848d2d57f2cda31572d07a9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482006
Reviewed-by: Eric Boren <borenet@google.com>
2021-12-09 20:16:29 +00:00
Brian Osman
3695bdb587 Refactor SkMatrixProvider slightly
There was only one virtual method, so switch that to a bool stored in
the base class. The derived types exist as hints for the reader, and an
easy way to adjust how the new localToDevice is constructed.

With this change, we don't need SkSimpleMatrixProvider. SkMatrixProvider
is concrete, so we can use it directly. SkOverrideDeviceMatrixProvider
no longer needs the original provider for anything, so remove that
parameter. It now exists solely to inhibit the hitsPixelCenters flag.

Fix a few spots (SkParticleBinding, some sites in SkRuntimeEffect) where
we used SkSimpleMatrixProvider, even though the local coordinates being
passed did not obey the hits-pixel-centers constraints.

Most importantly, document how localToDeviceHitsPixelCenters works.

Change-Id: Ibe9060bac0822d0edf52a507d390bd198d8e6dbd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/482176
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-12-09 20:10:58 +00:00