dawn-cmake/test
Austin Eng 38fa643702 Add HLSL/MSL generator options for ArrayLengthFromUniform
ArrayLengthFromUniform is needed for correct bounds checks on
dynamic storage buffers on D3D12. The intrinsic GetDimensions does
not return the actual size of the buffer binding.

ArrayLengthFromUniform is updated to output the indices of the
uniform buffer that are statically used. This allows Dawn to minimize
the amount of data needed to upload into the uniform buffer.
These output indices are returned on the HLSL/MSL generator result.

ArrayLengthFromUniform is also updated to allow only some of the
arrayLength calls to be replaced with uniform buffer loads. For HLSL
output, the remaining arrayLength computations will continue to use
GetDimensions(). For MSL, it is invalid to not specify an index into
the uniform buffer for all storage buffers.

After Dawn is updated to use the array_length_from_uniform option in the
Metal backend, the buffer_size_ubo_index member for MSL output may be
removed.

Bug: dawn:429
Change-Id: I9da4ec4a20882e9f1bfa5bb026725d72529eff26
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/69301
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: James Price <jrprice@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>
2021-11-19 04:11:33 +00:00
..
access GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
array HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
buffer HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
bug HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
expressions GLSL: implement inf, nan. 2021-11-18 13:11:43 +00:00
intrinsics GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
layout/storage/mat2x2 HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
let GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
loops HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
matrix/constructor/elements GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
ptr_ref GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
samples HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
shader_io GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
statements HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
struct GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
types GLSL: add .expected.glsl files for all tests. 2021-11-16 15:15:36 +00:00
unittest/reader/spirv Add more SPIR-V reader unit test samples 2021-09-27 20:55:53 +00:00
var HLSL: force FXC to never unroll loops 2021-11-18 13:50:12 +00:00
vk-gl-cts spirv-reader: Sink pointer-to-vector-component 2021-11-04 19:55:57 +00:00
BUILD.gn Add HLSL/MSL generator options for ArrayLengthFromUniform 2021-11-19 04:11:33 +00:00
extract-spvasm.py Add --dump-spirv option to tint_unittests 2021-05-05 09:46:31 +00:00
test-all.sh main: Replace --dawn-validation with --validate 2021-06-02 21:02:34 +00:00