Commit Graph

11869 Commits

Author SHA1 Message Date
James Price 66d487395d tint: Use PI/2 as the input value for sin tests
This makes the output value consistent between different platforms.

Change-Id: I4f94da4deac6998c4b809b03ed3b8f58d32bb1b0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121501
Commit-Queue: James Price <jrprice@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-24 18:57:39 +00:00
Ben Clayton 1a1b5278d5 tint/transform: Inline HLSL uniform / storage buffers
Change the DecomposeMemoryAccess to behave more like the DirectVariableAccess transform, in that it'll inline the access of buffer variable into the load / store helper functions, instead of passing the array down.

This avoids large array copies observed with FXC, which can have *severe* performance costs.

Fixed: tint:1819
Change-Id: I52eb3f908813f72ab9da446743e24a2637158309
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121460
Kokoro: Kokoro <noreply+kokoro@google.com>
Auto-Submit: Ben Clayton <bclayton@google.com>
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: James Price <jrprice@google.com>
2023-02-24 17:16:55 +00:00
Ben Clayton 7052cb57ff Revert "Add test setting the locale."
This reverts commit 9cdc3343ff.

Reason for revert: For some reason, Windows kokoro bots are now taking objection to this test.

Original change's description:
> Add test setting the locale.
>
> This CL adds a test which sets the locale to one which uses `1,00`
> instead of `1.00`. This ensures the float emission will get the right
> format.
>
> Bug: tint:1686
> Change-Id: Ib87235c7beac351b7dcbf37534df07135da377e5
> Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120881
> Reviewed-by: Ben Clayton <bclayton@google.com>
> Kokoro: Kokoro <noreply+kokoro@google.com>
> Commit-Queue: Dan Sinclair <dsinclair@chromium.org>

TBR=dsinclair@chromium.org,bclayton@google.com,noreply+kokoro@google.com,dawn-scoped@luci-project-accounts.iam.gserviceaccount.com

Change-Id: I2ace266871958a2d467855d55079aae467195ce0
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: tint:1686
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121462
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: James Price <jrprice@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-24 17:03:59 +00:00
Austin Eng 9ec746e3b9 Disable async pipeline compilation on Mac AMD with backend validation
Instead, compile pipelines synchronously.

When backend validation is on with Mac AMD, the driver crashes during
pipeline compilation. This seems to only occur when partition alloc
is enabled.

Bug: dawn:1200
Change-Id: I520087eeae9c356990962d0c4a96eba017735af1
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121400
Commit-Queue: Austin Eng <enga@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2023-02-24 16:26:00 +00:00
Dawn Autoroller d436ee4dbd Roll ANGLE from 7189e4cfe43b to e21c1efb06c6 (6 revisions)
7189e4cfe4..e21c1efb06

2023-02-24 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 64eb04027b9f to dca80fc3a894 (2 revisions)
2023-02-24 bsheedy@chromium.org Add support for permissive pixel comparison
2023-02-24 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 6aac6345f869 to 779fe76a4b87 (655 revisions)
2023-02-24 mark@lunarg.com Tests: Add SLAM DUNK from TV Animation trace
2023-02-24 cnorthrop@google.com TraceTests: Add a screenshot frame member variable
2023-02-24 tperrotta@google.com Update yapf style from "chromium" to "yapf"

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-dawn-autoroll
Please CC angle-team+autoroll@google.com,shrekshao@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: I101d15c2030c88dc5bb296553d712421cc9514b9
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121480
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2023-02-24 14:26:32 +00:00
Yan,Shaobo e958db0490 Add ExternalTexture::Refresh() and ExternalTexture::Expire()
ExternalTexture has active, expired and destroyed states.

Only active state external texture is valid to submit.

Expired state external texture can be refresh to active but
destroyed external texture cannot be refresh.

Bug: chromium:1412338
Change-Id: Ic7f12d274d27b644f19ec3ef8b46c110610afa2b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120982
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Shaobo Yan <shaobo.yan@intel.com>
2023-02-24 02:09:38 +00:00
Jiawei Shao dd0332ec91 D3D12: Add workaround for DstAlpha blend factor issue on Intel GPUs
On Intel Gen9 and Gen9.5 GPUs there is a D3D12 driver bug about
using DstAlpha as the source blend factors in both color and alpha
blending.

Although we cannot add workaround for all such cases, we have
confirmed that when the blend operation is 'add', and the
destination blend factors are ‘zero', we can workaround this driver
bug by replacing 'add' to 'minus'. We cannot add workaround when
destination blend factor is another value.

This patch adds such workaround on the affected platforms.

Bug: dawn:1579
Test: dawn_end2end_tests
Change-Id: If7c82b9d559b876e42fb36e2f539f9ff2f71ea91
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120981
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2023-02-24 01:34:56 +00:00
Li Hao fa5cda877f Add workaround to blit depth to depth in D3D12 T2T
Workaround for T2T depth copy failed with non-zero array layers for
d32s8 format on Intel D3D driver 31.0.101.4091.

Bug: dawn:1083

Change-Id: I9368f81ded765c5af4f132eb7f1032e695e16875
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121161
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Hao Li <hao.x.li@intel.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2023-02-24 01:17:58 +00:00
Dawn Autoroller 8bd09f33e1 Roll ANGLE from 389b86e7d76c to 7189e4cfe43b (12 revisions)
389b86e7d7..7189e4cfe4

2023-02-23 hailinzhang@google.com vulkan: fix depth buffer renderpass loadOp issue.
2023-02-23 dcheng@chromium.org Define enable_safe_libcxx in build_overrides/build.gni.
2023-02-23 cnorthrop@google.com Traces: Add key frame support
2023-02-23 lexa.knyazev@gmail.com Refine sRGB mipmap generation
2023-02-23 abdolrashidi@google.com Vulkan: Use VMA suballocation for images
2023-02-23 abdolrashidi@google.com Update the common cube map texture in MipmapTest
2023-02-23 ynovikov@chromium.org Reenable GLES 1.0 conformance tests on Win/Intel
2023-02-23 ynovikov@chromium.org Keep MemoryBarrier macro defined
2023-02-23 ynovikov@chromium.org Update extension data
2023-02-23 jonahr@google.com Change enum allocation for EGL_PLATFORM_ANGLE_DISPLAY_KEY_ANGLE
2023-02-23 max@igalia.com Remove obsolete additional_readme_paths.json entries
2023-02-23 brucedawson@chromium.org Copy d3dcompiler_47.dll on ARM64 Windows builds

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-dawn-autoroll
Please CC angle-team+autoroll@google.com,shrekshao@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: If69332344363a17a67abf98c3ddbb6d105fe17c6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121380
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2023-02-24 01:12:33 +00:00
dan sinclair 65a45fdf41 Handle errors in SPIRV-Reader tests.
This CL updates some EXPECT to ASSERT in the spirv-reader tests to
work around segvs when tests fail.

Bug: tint:1686
Change-Id: Icfd5a83cc71709fd351c3d5a39a9a0173056a0f8
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121340
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
2023-02-23 21:51:15 +00:00
Ben Clayton 107aa81c89 tint: Improve error for assignment to immutable variable
Fixed: tint:1835
Change-Id: I48d1380fd6d9d5fdaae4a210e3c8695e26894905
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121320
Commit-Queue: Ben Clayton <bclayton@chromium.org>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-23 20:50:36 +00:00
dan sinclair 9cdc3343ff Add test setting the locale.
This CL adds a test which sets the locale to one which uses `1,00`
instead of `1.00`. This ensures the float emission will get the right
format.

Bug: tint:1686
Change-Id: Ib87235c7beac351b7dcbf37534df07135da377e5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120881
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
2023-02-23 19:49:07 +00:00
dan sinclair 077d97a387 Add `SuggestAlternatives` to attributes.
This CL adds an `attribute` enum into intrinsics.def and updates the
WGSL parser to use the enum parser and SuggestAlternatives.

Bug: tint:1831
Change-Id: I33b3e6bbf092282d9b1f86a1080e69940f55ff68
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121280
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-23 19:08:57 +00:00
Antonio Maiorano 9386f73446 tint: Fix compilation error with latest MSVC 17.5.0
Not sure if MSVC is wrong here, but it now fails to compile this file
because it looks for `builtin::AddressSpace::kPrivate` within the inner
`builtin` namespace, rather than in `tint::builtin`.

Change-Id: I10f9e1bd58e6ba548d40823f03802320865f069d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121221
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
2023-02-23 18:35:49 +00:00
dan sinclair 869bcabf88 Make attribute grammar generic.
This Cl updates the parser to use a generic attribute grammar.

Bug: tint:1845
Change-Id: Icd600a2d87f03972f60d89b27fe0eef7be7667d5
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121100
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
2023-02-23 18:34:08 +00:00
Dawn Autoroller 20a82acf6a Roll SwiftShader from 3575b5479af5 to dca80fc3a894 (1 revision)
https://swiftshader.googlesource.com/SwiftShader.git/+log/3575b5479af5..dca80fc3a894

2023-02-23 bclayton@google.com tests/regres: Bump golang.org/x/text from 0.3.7 to 0.3.8

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/swiftshader-dawn-autoroll
Please CC shrekshao@google.com,webgpu-developers@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: I8fed2b2ff92d062aef9b7e16912da946e0bd189b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121300
Kokoro: Kokoro <noreply+kokoro@google.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2023-02-23 18:21:46 +00:00
jchen10 39b7330b5b Fix UV coord for TextureLoad
UV plane's coord should be half of that of Y plane for NV12.

Bug: chromium:1415832
Change-Id: Icee851e61eca1f7da291285100f8edcce482b511
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/119860
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Jie A Chen <jie.a.chen@intel.com>
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
2023-02-23 13:03:52 +00:00
Dawn Autoroller d8a13ee60c Roll ANGLE from 177936ace37d to 389b86e7d76c (1 revision)
177936ace3..389b86e7d7

2023-02-23 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from d9b79c6b8b96 to 6aac6345f869 (614 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-dawn-autoroll
Please CC angle-team+autoroll@google.com,shrekshao@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: Ib082e5f0bff2730918a0991641de336dea4479ce
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121180
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2023-02-23 11:01:33 +00:00
Dawn Autoroller b7faf4d918 Roll SwiftShader from 64eb04027b9f to 3575b5479af5 (1 revision)
https://swiftshader.googlesource.com/SwiftShader.git/+log/64eb04027b9f..3575b5479af5

2023-02-23 pkasting@chromium.org Yet more C++20 build fixes.

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/swiftshader-dawn-autoroll
Please CC shrekshao@google.com,webgpu-developers@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: Ic56f101e21507a5d102a048cac703ad1025d7977
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121140
Kokoro: Kokoro <noreply+kokoro@google.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
2023-02-23 04:10:01 +00:00
Antonio Maiorano 9776edf161 tint: Improve error message for array element stride in uniform storage
Bug: tint:1806
Change-Id: I673c41ce64c1cd2eb75ac93bf1ff9c51dab1c1d0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121042
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: dan sinclair <dsinclair@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: James Price <jrprice@google.com>
2023-02-22 23:53:07 +00:00
shrekshao 182a7e89a6 Validate writable storage buffer bindings don't alias
Validate as the bind group lazy aspect at each dispatch/draw
call.

Use nested loops to iterate through each bind group and binding
to find if any aliasing exists, which has time complexity of
O(N^2) and can be further optimized to use O(NlogN) algorithm.

Bug: dawn:1642
Change-Id: I8c43128cdeea75352c194752fb22258b6a73430e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/118440
Commit-Queue: Shrek Shao <shrekshao@google.com>
Reviewed-by: Loko Kung <lokokung@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 23:20:50 +00:00
Dawn Autoroller 1dac81a23d Roll ANGLE from 31684d8c336a to 177936ace37d (2 revisions)
31684d8c33..177936ace3

2023-02-22 kkinnunen@apple.com Metal: disable 32-bit float filtering on iOS
2023-02-22 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 5d2ee2959f28 to d9b79c6b8b96 (576 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-dawn-autoroll
Please CC angle-team+autoroll@google.com,shrekshao@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: Ib587cc6f0576be19245ae7be5c682f031147b4d7
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121080
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 21:15:58 +00:00
dan sinclair 187e0d5fe7 Add `requires` directive
This Cl adds the requires directive into Tint. Using the directive is
currently always an error as there is no valid value which can be used.

Bug: tint:1843
Change-Id: Idf77ba4e95ff0c1e177d02d1ba9598edc89a9812
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120740
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: David Neto <dneto@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
2023-02-22 20:57:28 +00:00
Loko Kung f35f1ff98c Refactors native mock classes to be more like the Null device.
- Plumbs all descriptors through so that the objects act much more like
  a real implementation.
- Lots of changes to DestroyObjectTests.cpp to update usages and test
  through the APIs when applicable.
- Put in defaults for the mock device and make it as easy to use as
  possible.

Change-Id: I85b243a18ec1872aff0172549aec0f599967ea0e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/119821
Reviewed-by: Austin Eng <enga@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Loko Kung <lokokung@google.com>
2023-02-22 20:38:37 +00:00
Ben Clayton 54a104e28f tint: Update constructor / conversion terminology
Rename:
* "type initializer" -> "value constructor"
* "type conversion" -> "value conversion"

Fixed: tint:1848
Change-Id: I3e86a4e944971cea970f0d137641517c36cb807d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121060
Auto-Submit: Ben Clayton <bclayton@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 20:04:40 +00:00
Corentin Wallez cce5f48f0e Triage CTS failures
Bug: dawn:1677 dawn:1676 chromium:1410936
Change-Id: I3cc0e84b45dee7c97785c497e36cce8cbc169f74
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120984
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2023-02-22 20:02:55 +00:00
Antonio Maiorano 4be42e57de tint/run-cts: make dump-shaders also disable symbol renaming
Change-Id: If9e0db103135e3c7c7928a91f6995c56938bec3d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121040
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 19:58:53 +00:00
Corentin Wallez b4d2bbb24f Make Texture/QuerySet destroy always valid.
This follows the recent semantic from the WebGPU spec and fixes a couple
failing CTS tests.

Bug: None
Change-Id: I9197ea3fda6c15bd9302f8d60e70ee00f1d37708
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120980
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 18:12:57 +00:00
Austin Eng f16b9bbd6e Guard D3D12_FEATURE_D3D12_OPTIONS13 behind SDK version check
Bug: dawn:1216
Change-Id: I29054d51a5c4a24ce85619a22062973572eb1c61
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120983
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 17:27:04 +00:00
Ben Clayton afc53fa942 tint/resolver: Bring back enum suggestions
The dependency graph no longer errors if a symbol cannot be resolved, instead the ResolvedIdentifier now has an unresolved variant.
This is required as the second resolve phase only has the full context of the identifier usage, to provide the hints.

Also: Split Slice out of the utils/vector.h, so it can be used as a lightweight view over static data.

Fixed: tint:1842
Change-Id: I31fa7697790be24c35b7e4fab5ca903c8a7afbba
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121020
Commit-Queue: Ben Clayton <bclayton@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
2023-02-22 17:15:53 +00:00
Ben Clayton b549b3051e tint: Validate @must_use on functions and builtins
Fixed: tint:1844
Change-Id: I812dd338925c1dccaa3029a46e10a0ea34a8ed54
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120960
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@chromium.org>
2023-02-22 16:18:22 +00:00
Ben Clayton d84903201d tools: Add @must_use support to intrinsics.def
Emits the new OverloadFlag::kMustUse flag on the annotated overloads.
Nothing consumes this, yet.

Bug: tint:1844
Change-Id: I4eb0943a23eaf5de98cd63444a686cffe62fb36e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120920
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Auto-Submit: Ben Clayton <bclayton@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
2023-02-22 13:52:21 +00:00
dan sinclair ce10962d82 Add parsing and emission of the `must_use` attribute.
This CL adds parsing of the `@must_use` attribute into the WGSL parser. The WGSL
generator is also updated to emit the attribute.

Bug: tint:1844
Change-Id: If8821c9ac534b866cbe042128a00a582a245c3de
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120821
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Auto-Submit: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
2023-02-22 13:36:01 +00:00
Dawn Autoroller dd57720d14 Roll ANGLE from c23dbe331608 to 31684d8c336a (11 revisions)
c23dbe3316..31684d8c33

2023-02-22 syoussefi@chromium.org Vulkan: Lazily create swapchain image views
2023-02-22 syoussefi@chromium.org Vulkan: Remove usage of VK_EXT_external_memory_host
2023-02-22 penghuang@chromium.org Fix EGLImage importing problem
2023-02-22 i.nazarov@samsung.com Revert "Fix dEQP-EGL.functional.mutable_render_buffer#basic"
2023-02-21 lexa.knyazev@gmail.com Add EXT_texture_mirror_clamp_to_edge entry points
2023-02-21 syoussefi@chromium.org Vulkan: Prune all statements without side effect
2023-02-21 kkinnunen@apple.com Metal: Fix crashes in EXT_b_f_e using temporaries
2023-02-21 lexa.knyazev@gmail.com Vulkan: Fix border color adjustment for emulated formats
2023-02-21 j.vigil@samsung.com EGL: Enable wayland types with autogen
2023-02-21 syoussefi@chromium.org Translator: Validate correct op usage in nodes
2023-02-21 i.nazarov@samsung.com Vulkan: Fix invalid assert in ContextVk::onSurfaceUnMakeCurrent

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-dawn-autoroll
Please CC angle-team+autoroll@google.com,shrekshao@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: I543fbd63addf803647f73ece559eea0426d554e4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121000
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-22 07:58:48 +00:00
Ben Clayton 5662f79b24 tint/ast: Remove unnecessary ast:: prefixes
These uses are already in the ast namespace, so do not need the extra qualification.

Change-Id: I5e66048c9485c55b72e61ffa5b85b17ba1c780d0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120761
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Commit-Queue: Ben Clayton <bclayton@chromium.org>
2023-02-22 00:08:55 +00:00
Austin Eng 4a88a3287e D3D12: derive T2T workaround from TextureCopyBetweenDimensionsSupported
Query D3D12_FEATURE_DATA_D3D12_OPTIONS13 to determine whether the device
supports copies between textures of different dimensions. If it does
not, or if D3D12_FEATURE_D3D12_OPTIONS13 is not supported, force enable
toggle
D3D12UseTempBufferInTextureToTextureCopyBetweenDifferentDimensions.

Fixed: dawn:1216
Change-Id: I976e7fad291126f8dcee31ce6b681314d38e69e7
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120882
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Auto-Submit: Austin Eng <enga@chromium.org>
2023-02-21 23:14:46 +00:00
Shrek Shao 053fca884a Run SubstituteOverride transform before Robustness
Fixed: dawn:1673
Change-Id: I57f3daf16c417713a850894d1c6fcbc31ef03da1
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120822
Commit-Queue: Shrek Shao <shrekshao@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
2023-02-21 23:12:33 +00:00
James Price 239b4298b3 tint/HoistToDeclBefore: Use explicit types
Hoisting a constant array with an abstract type may change its
materialized type when using type inference, so use explicit typing
instead.

Fixed: tint:1847
Change-Id: I890826945bac7a2b7d8a0b84967f9d3c9ba439b7
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120901
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: James Price <jrprice@google.com>
2023-02-21 23:10:17 +00:00
Ben Clayton 60d3738102 tint: Fix ICE in ast::TemplatedIdentifier ctor
Invalid programs could attempt to construct an ast::TemplatedIdentifier with no template arguments.
In this situation an ast::Identifier should be constructed instead.

Bug: chromium:1417465
Change-Id: Id1516cd83679947b5346c69ce5453d72f4f93b49
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120841
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-21 22:01:48 +00:00
dan sinclair 2f689a7efe Remove deprecated inspector fields.
This CL removes two deprecated fields from the inspector. The deprecated
alias to sem::SamplerTexturePair remains as it will require creating a
structure on the inspector side to replicate.

Change-Id: I6001fbd475260079dd49d50f8e8619241bb0b468
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120880
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
2023-02-21 21:54:48 +00:00
Ben Clayton fdef033210 tint/resolver: Fix ICE in ResolvedIdentifier::String()
That resolve to parameters.

Bug: chromium:1417513
Change-Id: Id7722524acbd9a9a26543cb73f48c8823dd51356
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120840
Kokoro: Ben Clayton <bclayton@chromium.org>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@chromium.org>
2023-02-21 21:07:35 +00:00
Ben Clayton f0b4dbb82d tint: Resolve @interpolate() args as expressions
This CL makes the builtin argument resolve as a shadowable enumerator
expression.

Bug: tint:1841
Bug: tint:1845
Change-Id: I5000ea91771fabb460c80c164bc7708fbbb0288c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120722
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-21 21:05:28 +00:00
Ben Clayton 650426b187 Run ./tools/format
Change-Id: Icf1925cd3c862c4e29ba41f7d8470991ba4017f3
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120721
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-21 21:05:28 +00:00
dan sinclair a79c6603b2 Add `@must_use` AST node.
This CL adds the `@must_use` ast node and hooks it into the
program_builder.

Bug: tint:1844
Change-Id: I2ffe99bbf29ec287446788253aa8cf63cc4da50b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120820
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
2023-02-21 18:49:40 +00:00
dan sinclair b92ff39724 Remove `static_assert` deprecation.
The `static_assert` builtin has been replaced with `const_assert`. This
CL removes the deprecation.

Bug: tint:1807
Change-Id: Ibcdc75e167bf6c1a6f74c295d9dcac7fff884d3a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120580
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
2023-02-21 18:44:16 +00:00
Dawn Autoroller 0aa2cef37e Roll ANGLE from f76ecaeed1d0 to c23dbe331608 (1 revision)
f76ecaeed1..c23dbe3316

2023-02-21 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 36ad54ddae32 to 5d2ee2959f28 (282 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-dawn-autoroll
Please CC angle-team+autoroll@google.com,shrekshao@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 Dawn: https://bugs.chromium.org/p/dawn/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

Bug: None
Tbr: shrekshao@google.com
Change-Id: I503b3bf1e5eae53a285c1533f4195c2dfda191e0
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120781
Commit-Queue: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Bot-Commit: Dawn Autoroller <dawn-autoroll@skia-public.iam.gserviceaccount.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2023-02-21 18:28:14 +00:00
Ben Clayton 4d3ff9711e tint: Resolve @builtin() args as expressions
This CL makes the builtin argument resolve as a shadowable enumerator
expression.

Bug: tint:1841
Bug: tint:1845
Change-Id: I2aaa2c63025752f25c113cf2fb38f4d91c2c16c2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120680
Kokoro: Ben Clayton <bclayton@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: James Price <jrprice@google.com>
2023-02-21 17:33:54 +00:00
dan sinclair 21571709a2 Remove the `type` keyword.
`type` has been deprecated in favour of `alias`. This CL removes the
deprecation warning and moves `type` to a reserved word.

Bug: tint:1812
Change-Id: I05246b9887a0890ae8343a0a132bd6f93353d5ae
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120540
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
2023-02-21 16:55:07 +00:00
Ben Clayton db9d4453f8 Roll third_party/webgpu-cts/ 87f8f3d61..13410d18b (2 commits)
Regenerated:
 - expectations.txt
 - ts_sources.txt
 - test_list.txt
 - cache_list.txt
 - resource_files.txt
 - webtest .html files


87f8f3d615..13410d18b4
 - 13410d Move `static_assert` and `type` to reserved words.
 - 2184a5 Update tests to use `alias`.

Created with './tools/run cts roll'

Change-Id: Ic00993d9fb940602af9f644faf785d3cb98e1bc1
Cq-Include-Trybots: luci.chromium.try:dawn-try-win10-x86-rel,linux-dawn-rel,mac-dawn-rel,win-dawn-rel
Include-Ci-Only-Tests: true
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120760
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Auto-Submit: Ben Clayton <bclayton@google.com>
2023-02-21 15:21:50 +00:00
Ben Clayton 2d6f90771b tint/reader/spirv: Remove stdout spam
Change-Id: I8e38535d32f3e82800740894d5d47256fa926b23
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120720
Auto-Submit: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
2023-02-21 01:59:33 +00:00