• Rename 'builtin-gen' back to 'intrinsic-gen', as 'intrinsics' now
include both builtins and operators.
• Move the intrinsic definitions, and IntrinsicTable to the resolver
package, where it belongs.
Bug: tint:1504
Change-Id: I5ad5c285c1e360a224ee1235c293ccd55eb2693d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/89025
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Tint has already implemented the enable directive for using WGSL
extension in the future, and using a WGSL extension that is not allowed
for the device should result in a shader creation error.
In this patch a WGSL extension allow list is added in DeviceBase, and
a validation is added in shader module base initialization to make sure
all extensions used in the WGSL program are in the allow list. This
patch also rename the `ValidateShaderModuleDescriptor` to
`ValidateAndParseShaderModule`, which is more descriptive for what it
actually does.
Bug: tint:1472
Change-Id: I4b039a3e37c25159b4fc6cfa37488aa817004ab2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88241
Commit-Queue: Zhaoming Jiang <zhaoming.jiang@intel.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
This change ensures that when errors are raised from WebGPU, including
lost context errors, they can include any associated Vulkan validation
layer messages in the message text if backend validation is enabled.
This will allow these messages to be surfaced in places like when
running CTS tests on browser build infrastructure.
Because of how Vulkan messages are raised at the instance level, some
routing of the messages to the appropriate device needed to be added.
This is based on appending message IDs to object labels and then parsing
them out of the message when it comes in.
This change also makes Vulkan validation messages cause a device loss,
which is inline with the behavior of the D3D12 backend.
Bug: dawn:1396
Change-Id: I2b309ba5475a338e7e99d4b4daaa7c3d5de61011
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88460
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Commit-Queue: Brandon Jones <bajones@chromium.org>
Unsuffixed integer literals are currently treated as i32,
but will shortly become AbstractInteger. To keep tests behaving
identically to how they are currently, change all test literals
to using either 'i' or 'u' suffixes.
Bug: tint:1504
Change-Id: Ic373d18ce1c718a16b6905568aec89da3641d36b
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88845
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
If the Switch() has a default case, then allow support for return types that do not have a default constructor.
Bug: tint:1504
Change-Id: I671ea78fe976138a786e2e0472e1e5f99afa0c5d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/89022
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
And use this to define constants for override vars in unit tests that
would fail for HLSL.
Bug: tint:1519
Change-Id: I4fd15c517868694d2bcd81d563399f817ed74ae6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88882
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Various things are deprecated or removed in C++20, including
* Various allocator member types
* std::iterator
* std::result_of
Replace these with supported versions.
Bug: chromium:1284275
Change-Id: I11a2909e3a269cdb98ada2bd6621086409878242
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/89040
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Auto-Submit: Peter Kasting <pkasting@google.com>
Commit-Queue: Peter Kasting <pkasting@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Use this for the BlockAllocator cast.
Bug: dawn:1406
Change-Id: Ic5d1acf7f8e74037fb51fc9d5d3b5141a15bd962
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/89021
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Ben Clayton <bclayton@chromium.org>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Use a memcpy to avoid a bad-cast seat belt which is firing in ChomeOS.
Bug: dawn:1406
Change-Id: I3acf0e2552ef8c5267e8c5701cc2f95f6e283c7a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/89020
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Bug: dawn:667
Change-Id: I6a78c7f6f9a850ef9ba30d3bafde9b198bab2edc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88940
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
For all i32 literal values.
Reduces risk of the SPIR-V reader producing WGSL that behaves
differently, when abstract-integers are fully implemented.
Bug: tint:1504
Change-Id: Ieaf8afec5b09c7978c75a38c6ed144633ddc017e
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88843
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Merge SintLiteralExpression and UintLiteralExpression with
IntLiteralExpression. IntLiteralExpression has a new Suffix field which
indicates whether the literal is either a:
• 'i' suffixed integer literal
• 'u' suffixed integer literal
• no-suffix integer literal
Have the SPIR-V reader produce no-suffixed literals for i32 types, to
keep this change small. In future changes the SPIR-V reader will
produce 'i' suffixed types for these.
Have all consumers of IntLiteralExpression treat unsuffixed integers the
same as 'i'-suffixed literals. Unsuffixed will be treated as abstract in
future changes.
Removed SemHelper::TypeOf(const ast::LiteralExpression* lit).
Fixed: tint:1510
Bug: tint:1504
Change-Id: I443f41984e637ddd948182ee756af1010c5f8226
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88842
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Generate different tokens for:
• 'i' suffixed integer literals
• 'u' suffixed integer literals
• no-suffix integer literals
'i' and no-suffix are currently both treated as i32, but this is the
first step to supporting abstract integers.
Bug: tint:1504
Change-Id: Ib94652e0c829d7879ff594ff7efd279cb05010e6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88841
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
This PR fixes one gn include issue and widens the GN check results
to test all but one of the GN targets. The remaining target is
disabled due to our absl configuration.
Bug: dawn:1372
Change-Id: I6e92a7aa777c3508e57d1e7138c73b7a92756db1
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88680
Reviewed-by: Brandon Jones <bajones@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
Required to roll Dawn -> Tint
Bug: dawn:1405
Change-Id: If60fe0bffe0052916ecb5e5b241f97aaaa43af46
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88840
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Adds a mutation that changes the operator used in a unary expression
to some other type-compatible operator.
Fixes: tint:1486
Change-Id: Icf87652fe9ceedcded88d47daece7401a7811873
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/87223
Kokoro: Kokoro <noreply+kokoro@google.com>
Auto-Submit: Alastair Donaldson <afdx@google.com>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Alastair Donaldson <afdx@google.com>
Update expectations and ts_sources
547d67bc22..249f2b797b
- 249f2b Don't block on subcases until the end of a testcase (#1335)
- 170d7b Sparse color attachment fix (#1344)
- 423df1 DevicePool: merge default holder into the DescriptorToHolderMap (#1343)
- 10ce93 remove doInit/doFinalize (#1342)
- d5cf9a Handle backends flushing inputs in `atan2` tests (#1340)
- 318d3d Move test device selection to an optional before clause (#1333)
- ece4eb Fix non-object-type test-parameter values (#1336)
- 5906dc Add --colors flag for enabling color output (#1338)
Created with './tools/run cts roll'
Change-Id: I070d813ffe3017e1bd4e425247f1ea174ee63887
Cq-Include-Trybots: luci.chromium.try:dawn-try-win10-x86-rel,linux-dawn-rel,mac-dawn-rel,win-dawn-rel
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88720
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>
• Add the included trybots in the CL description. All of these trybots are tested by the roll, but the final CQ-submit wouldn't necessarily test all of the variants before landing. This would mean that the 'cts export' could miss some results, as it takes the last PS with any results.
• Add --force flag to cts roll to force a roll. Useful for testing.
• Emit timing diagnostics for tests labelled 'Slow' instead of unhelpfully stating they pass.
• Enable the --cl and --ps flags for cts export
• Export with the most recent data to the top of the spreadsheet
Bug: dawn:1401
Change-Id: Id926367ab805bfb9f3032fce9cce7f00daf7a5d4
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88661
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
41e4d9a34 adjusted the tab indentation from 2 to 4 whitespaces.
Apply this to the templates so that regenerating these produce no diffs.
Bug: dawn:1339
Change-Id: Ib49e0d72b563558fbe2120d3db5754716eb1a4f6
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88663
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Don't emit colors if we're piping to a file, or the terminal does not support colors.
Always strip color escape code when writing to the --log file
Change-Id: Id15169f694563f06e950fdcab7344614b3f15e23
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88665
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Needed to fix Dawn -> Tint roll
Change-Id: I9b889320bbac6518620896ada7a53dd3cb95f01a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88662
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
'smoothStep' has been renamed to 'smoothstep'.
We cannot generate both sets of tests during this deprecation period as Windows and macOS can be file case-insensitive, and we'd have 'smoothstep' and 'smoothStep' as two sibling directories.
Bug: tint:1483
Change-Id: I944309585e8ff23345d9cc23669edf3774f3afb8
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88664
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
- No longer needed since the device information should be stored in the cache key.
Bug: dawn:549
Change-Id: I7c4e31e61df93ba317bc6eeb6a84074585f7eed2
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88365
Reviewed-by: Austin Eng <enga@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Shrek Shao <shrekshao@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>
- Adds testing for Vulkan pipeline caching.
- Removed redundant VK_NULL_HANDLE and use explicit {} initialization for 0 handles when necessary.
- Adds some const qualifiers where applicable and useful.
- Removes overloaded GetCacheKey (const/non-const) versions and exposed the cache key member directly for modifiers in derived classes.
Bug: dawn:549
Change-Id: I5e8ab9716eebc916b813c9d032f8dc1f3f5261bc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/86581
Commit-Queue: Loko Kung <lokokung@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
• Strip 'release-x64' tags.
These are always paired with 'release', and all
other tests just have the 'release' tag. This
means that results with the 'release' +
'release-x64' tags are a subset of just the
'release' tags, leading to many broken
assumptions in the expectation update.
• Don't consider tests with the error reason
'asyncio.exceptions.TimeoutError' as slow, but
as a failure. The CTS expectation updater will
already mark tests exceeding the config
threshold as slow. This reduces the amount of
data requested from resultdb, and prevents
failed rolls when results are actually
deadlocking.
• Fix inferring of patchset in GetResults().
LatestPatchest() was called but was assigned to
a nested scope.
Bug: dawn:1401
Change-Id: I57b2c9a029b31430d63a056f7b13c4bf1bc5b437
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/88450
Reviewed-by: Dan Sinclair <dsinclair@chromium.org>