Commit Graph

3 Commits

Author SHA1 Message Date
Ben Clayton 351ac4a009 transform::VarForDynamicIndex: Operate on matrices
Much like arrays, the SPIR-V writer cannot cope with dynamic indexing of matrices.

Fixed: tint:825
Change-Id: Ia111f15e0cf6fbd441861a4b3455a33b82b692ab
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/51781
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: David Neto <dneto@google.com>
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
Auto-Submit: Ben Clayton <bclayton@google.com>
2021-05-20 18:16:07 +00:00
Ben Clayton 9e32b20096 Add transform::VarForDynamicIndex
Use this as part of the Spirv sanitizer.
Cleans up buggy dynamic array indexing logic in the SPIR-V writer.

Fixed: tint:824
Change-Id: Ia408e49bd808bc8dbf3a1897eb47f9b33b71fdfb
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/51780
Commit-Queue: Ben Clayton <bclayton@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Auto-Submit: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
2021-05-20 11:55:28 +00:00
Ben Clayton d1232670ae test: Generate expected output for all tests
The expected output is far from perfect, and the generated HLSL and MSL
isn't even validated yet, so may be incorrect.

However, by committing the generated output, we get clear examples of
the currently generated output of each backend. As we land fixes and
improvements to each backend, the presubmits will require us to update
the expected test output, and so code reviews will include diffs of
each backend's generated output.

Change-Id: I5c2a9e5b796d0ab75b3ec4c7f8ad00a0a2ab166f
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/51224
Commit-Queue: Ben Clayton <bclayton@chromium.org>
Reviewed-by: David Neto <dneto@google.com>
2021-05-18 09:24:18 +00:00