diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/metal/simple-compute.slang | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/tests/metal/simple-compute.slang b/tests/metal/simple-compute.slang index e099704be..fe797dc2c 100644 --- a/tests/metal/simple-compute.slang +++ b/tests/metal/simple-compute.slang @@ -1,10 +1,17 @@ //TEST:SIMPLE(filecheck=CHECK): -target metal -RWStructuredBuffer<float> outputBuffer; +uniform RWStructuredBuffer<float> outputBuffer; + +// CHECK: {{.*}}kernel{{.*}} void main_kernel(float device* {{.*}}) + +void func(float v) +{ + outputBuffer[0] = v; + outputBuffer[1] = outputBuffer.Load(0); +} -// CHECK: {{.*}}kernel{{.*}} void main() [numthreads(1,1,1)] -void main() +void main_kernel() { - outputBuffer[0] = 1.0f; + func(3.0f); }
\ No newline at end of file |
