HLSL: Flatten structs for all non-arrayed I/O interfaces.
This commit is contained in:
@@ -87,16 +87,13 @@ Shader version: 500
|
||||
0:10 Constant:
|
||||
0:10 3 (const int)
|
||||
0:10 move second child to first child ( temp int)
|
||||
0:10 ii: direct index for structure ( temp int)
|
||||
0:10 '@entryPointOutput' (layout( location=0) out structure{ temp int ii})
|
||||
0:10 Constant:
|
||||
0:10 0 (const int)
|
||||
0:? '@entryPointOutput.ii' (layout( location=0) out int)
|
||||
0:10 ii: direct index for structure ( temp int)
|
||||
0:10 'flattenTemp' ( temp structure{ temp float clip0, temp float clip1, temp float cull0, temp float cull1, temp int ii})
|
||||
0:10 Constant:
|
||||
0:10 4 (const int)
|
||||
0:? Linker Objects
|
||||
0:? '@entryPointOutput' (layout( location=0) out structure{ temp int ii})
|
||||
0:? '@entryPointOutput.ii' (layout( location=0) out int)
|
||||
0:? 'ins.ii' ( in int InstanceIndex)
|
||||
0:? 'ins.clip0' (layout( location=0) in float)
|
||||
0:? 'ins.clip1' (layout( location=1) in float)
|
||||
@@ -197,16 +194,13 @@ Shader version: 500
|
||||
0:10 Constant:
|
||||
0:10 3 (const int)
|
||||
0:10 move second child to first child ( temp int)
|
||||
0:10 ii: direct index for structure ( temp int)
|
||||
0:10 '@entryPointOutput' (layout( location=0) out structure{ temp int ii})
|
||||
0:10 Constant:
|
||||
0:10 0 (const int)
|
||||
0:? '@entryPointOutput.ii' (layout( location=0) out int)
|
||||
0:10 ii: direct index for structure ( temp int)
|
||||
0:10 'flattenTemp' ( temp structure{ temp float clip0, temp float clip1, temp float cull0, temp float cull1, temp int ii})
|
||||
0:10 Constant:
|
||||
0:10 4 (const int)
|
||||
0:? Linker Objects
|
||||
0:? '@entryPointOutput' (layout( location=0) out structure{ temp int ii})
|
||||
0:? '@entryPointOutput.ii' (layout( location=0) out int)
|
||||
0:? 'ins.ii' ( in int InstanceIndex)
|
||||
0:? 'ins.clip0' (layout( location=0) in float)
|
||||
0:? 'ins.clip1' (layout( location=1) in float)
|
||||
@@ -217,14 +211,14 @@ Shader version: 500
|
||||
|
||||
// Module Version 10000
|
||||
// Generated by (magic number): 80001
|
||||
// Id's are bound by 73
|
||||
// Id's are bound by 70
|
||||
|
||||
Capability Shader
|
||||
Capability ClipDistance
|
||||
Capability CullDistance
|
||||
1: ExtInstImport "GLSL.std.450"
|
||||
MemoryModel Logical GLSL450
|
||||
EntryPoint Vertex 4 "main" 21 26 30 34 39 51 59 68
|
||||
EntryPoint Vertex 4 "main" 21 26 30 34 39 51 59 67
|
||||
Source HLSL 500
|
||||
Name 4 "main"
|
||||
Name 8 "S"
|
||||
@@ -246,9 +240,7 @@ Shader version: 500
|
||||
Name 44 "param"
|
||||
Name 51 "@entryPointOutput.clip1"
|
||||
Name 59 "@entryPointOutput.cull1"
|
||||
Name 66 "S"
|
||||
MemberName 66(S) 0 "ii"
|
||||
Name 68 "@entryPointOutput"
|
||||
Name 67 "@entryPointOutput.ii"
|
||||
Decorate 21(ins.clip0) Location 0
|
||||
Decorate 26(ins.clip1) Location 1
|
||||
Decorate 30(ins.cull0) Location 2
|
||||
@@ -256,7 +248,7 @@ Shader version: 500
|
||||
Decorate 39(ins.ii) BuiltIn InstanceIndex
|
||||
Decorate 51(@entryPointOutput.clip1) BuiltIn ClipDistance
|
||||
Decorate 59(@entryPointOutput.cull1) BuiltIn CullDistance
|
||||
Decorate 68(@entryPointOutput) Location 0
|
||||
Decorate 67(@entryPointOutput.ii) Location 0
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
6: TypeFloat 32
|
||||
@@ -285,10 +277,8 @@ Shader version: 500
|
||||
51(@entryPointOutput.clip1): 50(ptr) Variable Output
|
||||
54: TypePointer Output 6(float)
|
||||
59(@entryPointOutput.cull1): 50(ptr) Variable Output
|
||||
66(S): TypeStruct 7(int)
|
||||
67: TypePointer Output 66(S)
|
||||
68(@entryPointOutput): 67(ptr) Variable Output
|
||||
71: TypePointer Output 7(int)
|
||||
66: TypePointer Output 7(int)
|
||||
67(@entryPointOutput.ii): 66(ptr) Variable Output
|
||||
4(main): 2 Function None 3
|
||||
5: Label
|
||||
18(ins): 9(ptr) Variable Function
|
||||
@@ -329,10 +319,9 @@ Shader version: 500
|
||||
64: 6(float) Load 63
|
||||
65: 54(ptr) AccessChain 59(@entryPointOutput.cull1) 25
|
||||
Store 65 64
|
||||
69: 41(ptr) AccessChain 43(flattenTemp) 37
|
||||
70: 7(int) Load 69
|
||||
72: 71(ptr) AccessChain 68(@entryPointOutput) 19
|
||||
Store 72 70
|
||||
68: 41(ptr) AccessChain 43(flattenTemp) 37
|
||||
69: 7(int) Load 68
|
||||
Store 67(@entryPointOutput.ii) 69
|
||||
Return
|
||||
FunctionEnd
|
||||
12(@main(struct-S-f1-f1-f1-f1-i11;): 8(S) Function None 10
|
||||
|
||||
Reference in New Issue
Block a user