blob: 903afb144164961b56ebd4c078f6c73083fa3b86 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
//DISABLE_TEST:SIMPLE(filecheck=CHECK): -target hlsl -stage compute -entry computeMain
//DISABLE_TEST:SIMPLE(filecheck=CHECK): -target glsl -stage compute -entry computeMain
// CHECK-NOT: {{.* }}= 0;
RWStructuredBuffer<int> outputBuffer;
struct MyStruct_base
{
int a = 1;
int b;
};
struct MyStruct : MyStruct_base
{
int c = 1;
int d;
};
MyStruct getStruct()
{
MyStruct myStruct;
return myStruct;
}
[numthreads(1, 1, 1)]
void computeMain(int3 dispatchThreadID: SV_DispatchThreadID)
{
MyStruct myStruct = getStruct();
// BUF: 1
outputBuffer[0] = true
&& myStruct.a == 1
&& myStruct.b == 0
&& myStruct.c == 1
&& myStruct.d == 0
;
}
|