blob: 18bcb3b1e341e13861ca52dda9494dbc0875da82 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
//DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK): -target hlsl -entry computeMain -stage compute
//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=16):out
RWStructuredBuffer<int> outputBuffer;
// CHECK: error 20001
// Previously this definition would lead to an infinite loop in parsing.
int doThing<1>() { return 2; }
[numthreads(4, 4, 1)]
void computeMain(uint3 dispatchThreadID : SV_DispatchThreadID)
{
int index = dispatchThreadID.x;
outputBuffer[index] = index;
}
|