blob: ae8f916dd9357be4b62b0c9c9d688c0b701c2dd6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
//DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK): -target spirv
struct RecursiveFoo
{
float value;
//CHECK-DAG: ([[# @LINE+1]]): error 38205
StructuredBuffer<RecursiveFoo> children;
}
StructuredBuffer<RecursiveFoo> recursiveRoot;
RWStructuredBuffer<float> output;
[numthreads(4, 1, 1)]
void computeMain(uint3 dispatchThreadID : SV_DispatchThreadID)
{
uint i = dispatchThreadID.x;
RecursiveFoo foo = recursiveRoot[i];
float result = foo.value + foo.children[0].value + foo.children[0].children[0].value;
output[i] = result;
}
|