store() returns a success bool only because it can, because it wasn't
going to return any sort of skvm::Value anyway. But it should never
fail given a well-formed skvm::PixelFormat, e.g. one from
SkColorType_to_PixelFormat. So move the "error handling" inside, really
just asserting/assuming it doesn't fail.
And similarly, skvm::SkColorType_to_PixelFormat() can no longer fail, so
have it return the skvm::PixelFormat directly instead of the bool I used
to stage things back when building this out.
Change-Id: I6dc3b6da32cdaaef377fe59b8c94846e902841ee
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/367796
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
- Treat randomly generated control points as pre-projected
- Use double-precision conic evaluation for "within tolerance" test.
This allows us to test with larger magnitude control points (the
SkConic/SkGeometry single-precision functions lose too much accuracy).
Bug: skia:10419
Change-Id: Iba0915dccb50131e1a1b28a7d556863497f636e9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/367057
Commit-Queue: Tyler Denniston <tdenniston@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Cusps are rare, and simply detecting if a curve has one or not is
cheap. This CL handles cusps on the CPU side by chopping them into two
different patches joined by a bowtie. By removing cusps on the GPU
side, we greatly reduce the amount of complexity required in the
tessellation shaders. For now we only remove the line detection in
order to fix a rendering artifact, but in the future we will be able
to significantly simplifty these shaders.
Bug: chromium:1172543
Bug: skia:10419
Change-Id: I9c27c3cf002e0cbd91d4877f0ce7ec5a9136ef2b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/367018
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
These aren't used any more in favor of lazy proxies.
Bug: skia:11288
Change-Id: I992e1a3dd343e0ebc7f3a4f18c0054453dfebbaf
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366896
Commit-Queue: Adlai Holler <adlai@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
These cover new ground; when combined with some additional optimization
work, they can cause crashes in the optimizer that we don't see from any
existing test.
Change-Id: I3958a5522cfe0929d0753e6e617d72e032c7f5a3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/367063
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
b2de0688d7..6b20e1c884
2021-02-08 cnorthrop@google.com Tests: Add Hill Climb Racing trace
2021-02-08 cnorthrop@google.com Tests: Add Worms Zone io trace
2021-02-07 doughorn@google.com Micro-optimizations for setUniform*
2021-02-06 natsu@google.com Use __system_property* to read Android props
2021-02-05 cnorthrop@google.com Tests: Add Romancing Saga trace
2021-02-05 geofflang@chromium.org Skip happy_color trace on Windows AMD Vulkan
2021-02-05 ianelliott@google.com Create MSAA-swapchain windows' VkImages differently
2021-02-05 cnorthrop@google.com Tests: Add Rise of Kingdoms trace
2021-02-05 cnorthrop@google.com Tests: Add Clash Royale trace
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 borenet@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: borenet@google.com
Test: Test: Run the dEQP shader tests.Test: Test: angle_perftests --gtest_filter="*clash_royale*"Test: Test: angle_perftests --gtest_filter="*hill_climb_racing*"Test: Test: angle_perftests --gtest_filter="*rise_of_kingdoms*"Test: Test: angle_perftests --gtest_filter="*romancing_saga*"Test: Test: angle_perftests --gtest_filter="*worms_zone_io*"Test: Test: aosp/1574848 presubmitTest: Test: roll_aosp.sh && m && launch Cuttlefish w/ SwANGLE
Change-Id: I2ac7b4deec28f1f6ec6c00868b66cdaaaead9d32
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/367636
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
with unit test
Change-Id: I7f0e30435bf4e054fe7436daaadb3512936a58ac
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/367237
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
This is now structured like the VM generator: Just a function that does
the conversion. Moved all relevant types and constants out of the
compiler, too. The key thing is that we don't need/want an error
handler, because it's too late to fail. We *must* catch all errors
during IR generation.
This is also another step along the path of directly emitting to the
fragment shader builder, rather than generating strings with
placeholders.
Bug: skia:11127
Change-Id: I18591270aa6e56dae1f040275a4b7d4a245007db
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366956
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Change-Id: I3593e7ab0caac2fd572346038cbc8ff63e6fe970
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366406
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
SkSL.
It would previously catch 1 / 0, but fail to detect x / 0.
Bug: skia:11051
Change-Id: I3adb5942cce03a7ad40a13a8ca5d5a7f2029d6ad
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366720
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: Ethan Nicholas <ethannicholas@google.com>
Change-Id: Ifa5fa8bd80ffc48408f133f96951f8a74d572751
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366959
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Create a simple linked list to sequence the subruns preparing
the way for a more focused allocator for managing subruns
at the end of the GrTextBlob.
Change-Id: I595e2ce2810d161332a23405e4615724d2953471
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366957
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Herb Derby <herb@google.com>
Bug: skia:11226
Change-Id: I58fc7e02dc9ea9a06e855107aad4fbbd7b98d347
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366316
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Useful in client code to document what we're doing as we switch away
from SkFilterQuality.
Change-Id: I05737beb99a567a46a3c3ec418b7f7da71b1ff62
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366723
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Reed <reed@google.com>
This is largely mechanical, with large chunks of the GLSL generator
functionality removed. There are some obvious further improvements to be
made, but it should be easier starting from here.
Change-Id: I93b1aa1936c4151af83f83e6d03233d89682496d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366402
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
This takes away one of our gadgets for thwarting dead-code elimination
in unit tests, but it's the right thing to do. Comma expression left-
sides without side effects are clearly dead code.
Change-Id: Iaee490b4a742d06a0a0be94cddaa69a51543d8f5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366719
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
63e7ab8d63..b2de0688d7
2021-02-05 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 14dcbed947ce to ff010f9f0131 (2 revisions)
2021-02-05 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from f5e138b74576 to 19ae187233a0 (532 revisions)
2021-02-05 cnorthrop@google.com Tests: Add Happy Color trace
2021-02-05 cnorthrop@google.com Tests: Add Sniper 3D trace
2021-02-05 cnorthrop@google.com Tests: Add Coin Master trace
2021-02-05 jmadill@chromium.org Revert "Test Runner: Pick single/multi-process mode automatically."
2021-02-05 cnorthrop@google.com Tests: Add Fallout Shelter Online trace
2021-02-04 sokcevic@google.com Move metadata in OWNERS files to DIR_METADATA files
2021-02-04 jmadill@chromium.org Vulkan: Don't request aliased FB attachments.
2021-02-04 sugoi@google.com Enable packing extensions for the Vulkan backend
2021-02-04 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 6b006f95bb79 to f5e138b74576 (467 revisions)
2021-02-04 cnorthrop@google.com Tests: Add Shadow Fight 2 trace
2021-02-04 cnorthrop@google.com Tests: Add Hay Day trace
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 robertphillips@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: robertphillips@google.com
Test: Test: angle_perftest --gtest_filter="*coin_master*"Test: Test: angle_perftest --gtest_filter="*sniper_3d*"Test: Test: angle_perftests --gtest_filter="*fallout_shelter_online*"Test: Test: angle_perftests --gtest_filter="*happy_color*"Test: Test: angle_perftests --gtest_filter="*shadow_fight_2*"Test: Test: angle_perftests --gtest_filters="*hay_day*"
Change-Id: If577bcd6ae5b8bc2597874aaa8905a769a50150c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366816
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
This fixes the OutParamsTricky test.
Change-Id: If59637bc946b71b141ae1d90cf1652bf80b163c4
Bug: skia:11269
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366399
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Same as onProgram().
Change-Id: Ie0d72ba50d73e38b4064347a3b0c0bb3300ffc16
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366410
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
This reverts commit 3f95357c4c.
Reason for revert: I believe this is blocking the Chrome roll
Original change's description:
> Don't simplify strokes that could have been tessellated
>
> Bug: chromium:1172543
> Change-Id: I3be0d822ca0a338118059c7aa37b2fd7822869b8
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/362936
> Commit-Queue: Chris Dalton <csmartdalton@google.com>
> Reviewed-by: Robert Phillips <robertphillips@google.com>
TBR=robertphillips@google.com,csmartdalton@google.com,michaelludwig@google.com
Change-Id: Id574d974617423b44d1767d7a478ce39bea810fa
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:1172543
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366717
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
There is currently window of time where we have removed the Inbox
that receives messages about buffers that need to be unmapped and
the disposal (abandonment/releasing) by GrDirectContext.
If on another thread an async read result is released it will attempt
to post to the inbox and transfer its buffer ref along with the
posted message. However, the inbox is gone so it unrefs the
buffer and we delete the buffer on that thread instead of in
~GrDirectContext.
Speculative fix for:
Bug: chromium:1153592
Change-Id: I223bcedca624faa159b0f4c6fcb9e45aded64dff
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366403
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
This can wait until drawShapeUsingPathRenderer.
Bug: chromium:1172543
Change-Id: I3217084f89125ee90f67907a2e045394cf8ae839
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366147
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
If follow on change when I try to use cached buffers for read backs we
get into a state where we're doing normal readPixels but we still have
the buffer alive and it is still bound to PIXEL_PACK_BUFFER which causes
INVALID_OPERATION errors.
Bug: skia:11226
Change-Id: If5486cc2743908ee7222925afb372c1cfafef429
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366319
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
- MultipleAssignments
- NegatedVectorLiteral
- NumberCasts
- OutParams
- OutParamsTricky (disabled on GPU due to skia:11269)
Change-Id: I87dc9c5019931f3d2dc3aafbe1e02d0eee2e1a05
Bug: skia:11009, skia:11269
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366400
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Bug: chromium:1172543
Change-Id: I8c5f48cd7744755d5c207c53088912f0aa893369
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366146
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Bug:1172796
Change-Id: Ifc03709a0f978b4dec6c8f7ea2c721c860167abb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/366337
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
This adds a new version of emitFunction that operates directly on an
SkSL::FunctionDeclaration, which saves us the trouble of mapping the
return and parameter types back to the corresponding GrSLType.
It's also a pre-requisite for supporting functions that return or accept
types that can't be mapped like this (eg, structs or enums).
Bug: skia:10939, skia:11246
Change-Id: Ib5d2fb80a983efbf70fe8ce5ac3ba1d769e44d07
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/361562
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Also add a unit test that the vectorized version equals the reference
implementation.
Bug: skia:10419
Change-Id: I4d165fd45532e9ec468565d0637fb769b51f5fcd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/345122
Commit-Queue: Tyler Denniston <tdenniston@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>