diff options
Diffstat (limited to 'tests/spirv')
| -rw-r--r-- | tests/spirv/push-constant-space.slang | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/spirv/push-constant-space.slang b/tests/spirv/push-constant-space.slang new file mode 100644 index 000000000..847c60b7d --- /dev/null +++ b/tests/spirv/push-constant-space.slang @@ -0,0 +1,18 @@ +// Test that push constants should not occupy the default +// space. + +//TEST:SIMPLE(filecheck=CHECK): -target spirv + +// CHECK-NOT: OpDecorate {{.*}} DescriptorSet 1 + +struct Data { + StructuredBuffer<uint4> data; + RWStructuredBuffer<float> output; +}; +ParameterBlock<Data> gData; + +[numthreads(1,1,1)] +void taskMain(uniform uint a) +{ + gData.output[0] = gData.data[0].x + a; +} |
