commit | 857b1580c74193cdab72d77583859f5b96cab30f | [log] [tgz] |
---|---|---|
author | James Price <jrprice@google.com> | Wed Dec 21 22:59:14 2022 +0000 |
committer | Dawn LUCI CQ <dawn-scoped@luci-project-accounts.iam.gserviceaccount.com> | Wed Dec 21 22:59:14 2022 +0000 |
tree | 6b5e9ea7237da8e37c97dde36dce8148c707bb14 | |
parent | 1d77e2531c5e54385fa95608cc4e9f426a5e0bac [diff] |
tint/uniformity: Handle pointer uniformity This change is a necessary to support workgroupUniformLoad in a following patch. Otherwise, there is no change to the set of shaders that are accepted or rejected by the analysis. We now distinguish between uniformity requirements on the contents of a pointer parameter versus the pointer value itself when generating tags for function parameters. Whilst processing an expression, if we see a sem::Load node we pass a flag down through child expressions to indicate that we will be loading from the result. When processing an identifier expression, we can then select between adding an edge to the source of the pointer/reference versus the contents of the root identifier that it corresponds to. Since the pointers passed to atomic builtins can be uniform, we special-case them to capture the fact that their return value is always considered non-uniform. The arrayLength builtin no longer needs special-casing. Added many tests to cover various cases that are now captured differently in the graph. There are two cases that are disabled as they require variable pointers to trigger the uniformity violation. Bug: tint:1780 Change-Id: I03edb65f22a6ffb0e7daf8b2f590f5de898e6262 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/114861 Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: James Price <jrprice@google.com> Reviewed-by: David Neto <dneto@google.com>
Dawn is an open-source and cross-platform implementation of the work-in-progress WebGPU standard. More precisely it implements webgpu.h
that is a one-to-one mapping with the WebGPU IDL. Dawn is meant to be integrated as part of a larger system and is the underlying implementation of WebGPU in Chromium.
Dawn provides several WebGPU building blocks:
webgpu.h
version that Dawn implements.webgpu.h
.Helpful links:
Developer documentation:
User documentation: (TODO, figure out what overlaps with the webgpu.h docs)
(TODO)
Apache 2.0 Public License, please see LICENSE.
This is not an officially supported Google product.