Flatten all interface variables (#2217)

Specifically, add flattening of arrayed io for geometry and
tesselation shaders. Previously some interface structs just had
builtins split out which caused some interfaces to not be exactly
the same as that of flattened adjacent stages, affecting validation
and correctness.

This obviates builtin splitting. That will be removed in a followup
commit. It was left in for this commit to better exhibit the functional
changes that were made.

Fixes #1660.
This commit is contained in:
greg-lunarg 2020-05-18 02:13:10 -06:00 committed by GitHub
parent 1a906168cd
commit 7c753a7253
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 3325 additions and 1561 deletions

View file

@ -89,23 +89,108 @@ triangle order = cw
0:63 Function Definition: main( ( temp void)
0:63 Function Parameters:
0:? Sequence
0:63 move second child to first child ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' (layout( location=0) in 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Sequence
0:63 move second child to first child ( temp 3-component vector of float)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 0 (const int)
0:63 Constant:
0:63 0 (const int)
0:63 direct index (layout( location=0) in 3-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:63 Constant:
0:63 0 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 0 (const int)
0:63 Constant:
0:63 1 (const int)
0:63 direct index (layout( location=1) in 4-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:63 Constant:
0:63 0 (const int)
0:63 move second child to first child ( temp 3-component vector of float)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 1 (const int)
0:63 Constant:
0:63 0 (const int)
0:63 direct index (layout( location=0) in 3-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:63 Constant:
0:63 1 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 1 (const int)
0:63 Constant:
0:63 1 (const int)
0:63 direct index (layout( location=1) in 4-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:63 Constant:
0:63 1 (const int)
0:63 move second child to first child ( temp 3-component vector of float)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 2 (const int)
0:63 Constant:
0:63 0 (const int)
0:63 direct index (layout( location=0) in 3-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:63 Constant:
0:63 2 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 2 (const int)
0:63 Constant:
0:63 1 (const int)
0:63 direct index (layout( location=1) in 4-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:63 Constant:
0:63 2 (const int)
0:63 move second child to first child ( temp uint)
0:? 'pointId' ( temp uint)
0:? 'pointId' ( in uint InvocationID)
0:63 move second child to first child ( temp uint)
0:? 'patchId' ( temp uint)
0:? 'patchId' ( in uint PrimitiveID)
0:63 move second child to first child ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 indirect index (layout( location=0) out structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? '@entryPointOutput' (layout( location=0) out 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'pointId' ( in uint InvocationID)
0:63 Function Call: @main(struct-HullInputType-vf3-vf41[3];u1;u1; ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'pointId' ( temp uint)
0:? 'patchId' ( temp uint)
0:63 Sequence
0:63 move second child to first child ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 'flattenTemp' ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Function Call: @main(struct-HullInputType-vf3-vf41[3];u1;u1; ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'pointId' ( temp uint)
0:? 'patchId' ( temp uint)
0:63 move second child to first child ( temp 3-component vector of float)
0:63 indirect index (layout( location=0) out 3-component vector of float)
0:? '@entryPointOutput.position' (layout( location=0) out 3-element array of 3-component vector of float)
0:? 'pointId' ( in uint InvocationID)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 'flattenTemp' ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 0 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 indirect index (layout( location=1) out 4-component vector of float)
0:? '@entryPointOutput.color' (layout( location=1) out 3-element array of 4-component vector of float)
0:? 'pointId' ( in uint InvocationID)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 'flattenTemp' ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 1 (const int)
0:? Barrier ( temp void)
0:? Test condition and select ( temp void)
0:? Condition
@ -168,8 +253,10 @@ triangle order = cw
0:? 1 (const int)
0:? Linker Objects
0:? 'anon@0' (layout( binding=0 row_major std140) uniform block{layout( row_major std140) uniform float tessellationAmount, layout( row_major std140) uniform 3-component vector of float padding})
0:? '@entryPointOutput' (layout( location=0) out 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' (layout( location=0) in 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? '@entryPointOutput.position' (layout( location=0) out 3-element array of 3-component vector of float)
0:? '@entryPointOutput.color' (layout( location=1) out 3-element array of 4-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:? 'pointId' ( in uint InvocationID)
0:? 'patchId' ( in uint PrimitiveID)
0:? '@patchConstantOutput.edges' ( patch out 4-element array of float TessLevelOuter)
@ -269,23 +356,108 @@ triangle order = cw
0:63 Function Definition: main( ( temp void)
0:63 Function Parameters:
0:? Sequence
0:63 move second child to first child ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' (layout( location=0) in 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Sequence
0:63 move second child to first child ( temp 3-component vector of float)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 0 (const int)
0:63 Constant:
0:63 0 (const int)
0:63 direct index (layout( location=0) in 3-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:63 Constant:
0:63 0 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 0 (const int)
0:63 Constant:
0:63 1 (const int)
0:63 direct index (layout( location=1) in 4-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:63 Constant:
0:63 0 (const int)
0:63 move second child to first child ( temp 3-component vector of float)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 1 (const int)
0:63 Constant:
0:63 0 (const int)
0:63 direct index (layout( location=0) in 3-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:63 Constant:
0:63 1 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 1 (const int)
0:63 Constant:
0:63 1 (const int)
0:63 direct index (layout( location=1) in 4-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:63 Constant:
0:63 1 (const int)
0:63 move second child to first child ( temp 3-component vector of float)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 2 (const int)
0:63 Constant:
0:63 0 (const int)
0:63 direct index (layout( location=0) in 3-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:63 Constant:
0:63 2 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 direct index ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 2 (const int)
0:63 Constant:
0:63 1 (const int)
0:63 direct index (layout( location=1) in 4-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:63 Constant:
0:63 2 (const int)
0:63 move second child to first child ( temp uint)
0:? 'pointId' ( temp uint)
0:? 'pointId' ( in uint InvocationID)
0:63 move second child to first child ( temp uint)
0:? 'patchId' ( temp uint)
0:? 'patchId' ( in uint PrimitiveID)
0:63 move second child to first child ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 indirect index (layout( location=0) out structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? '@entryPointOutput' (layout( location=0) out 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'pointId' ( in uint InvocationID)
0:63 Function Call: @main(struct-HullInputType-vf3-vf41[3];u1;u1; ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'pointId' ( temp uint)
0:? 'patchId' ( temp uint)
0:63 Sequence
0:63 move second child to first child ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 'flattenTemp' ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Function Call: @main(struct-HullInputType-vf3-vf41[3];u1;u1; ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' ( temp 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'pointId' ( temp uint)
0:? 'patchId' ( temp uint)
0:63 move second child to first child ( temp 3-component vector of float)
0:63 indirect index (layout( location=0) out 3-component vector of float)
0:? '@entryPointOutput.position' (layout( location=0) out 3-element array of 3-component vector of float)
0:? 'pointId' ( in uint InvocationID)
0:63 position: direct index for structure ( temp 3-component vector of float)
0:63 'flattenTemp' ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 0 (const int)
0:63 move second child to first child ( temp 4-component vector of float)
0:63 indirect index (layout( location=1) out 4-component vector of float)
0:? '@entryPointOutput.color' (layout( location=1) out 3-element array of 4-component vector of float)
0:? 'pointId' ( in uint InvocationID)
0:63 color: direct index for structure ( temp 4-component vector of float)
0:63 'flattenTemp' ( temp structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:63 Constant:
0:63 1 (const int)
0:? Barrier ( temp void)
0:? Test condition and select ( temp void)
0:? Condition
@ -348,8 +520,10 @@ triangle order = cw
0:? 1 (const int)
0:? Linker Objects
0:? 'anon@0' (layout( binding=0 row_major std140) uniform block{layout( row_major std140) uniform float tessellationAmount, layout( row_major std140) uniform 3-component vector of float padding})
0:? '@entryPointOutput' (layout( location=0) out 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? 'patch' (layout( location=0) in 3-element array of structure{ temp 3-component vector of float position, temp 4-component vector of float color})
0:? '@entryPointOutput.position' (layout( location=0) out 3-element array of 3-component vector of float)
0:? '@entryPointOutput.color' (layout( location=1) out 3-element array of 4-component vector of float)
0:? 'patch.position' (layout( location=0) in 3-element array of 3-component vector of float)
0:? 'patch.color' (layout( location=1) in 3-element array of 4-component vector of float)
0:? 'pointId' ( in uint InvocationID)
0:? 'patchId' ( in uint PrimitiveID)
0:? '@patchConstantOutput.edges' ( patch out 4-element array of float TessLevelOuter)
@ -357,12 +531,12 @@ triangle order = cw
// Module Version 10000
// Generated by (magic number): 80008
// Id's are bound by 127
// Id's are bound by 159
Capability Tessellation
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint TessellationControl 4 "main" 72 76 79 83 110 123
EntryPoint TessellationControl 4 "main" 73 80 99 102 113 120 142 155
ExecutionMode 4 OutputVertices 3
ExecutionMode 4 Triangles
ExecutionMode 4 SpacingEqual
@ -392,33 +566,38 @@ triangle order = cw
Name 35 ""
Name 56 "output"
Name 70 "patch"
Name 72 "patch"
Name 74 "pointId"
Name 76 "pointId"
Name 78 "patchId"
Name 79 "patchId"
Name 83 "@entryPointOutput"
Name 85 "param"
Name 87 "param"
Name 89 "param"
Name 102 "@patchConstantResult"
Name 103 "param"
Name 73 "patch.position"
Name 80 "patch.color"
Name 97 "pointId"
Name 99 "pointId"
Name 101 "patchId"
Name 102 "patchId"
Name 104 "flattenTemp"
Name 105 "param"
Name 110 "@patchConstantOutput.edges"
Name 123 "@patchConstantOutput.inside"
Name 107 "param"
Name 109 "param"
Name 113 "@entryPointOutput.position"
Name 120 "@entryPointOutput.color"
Name 134 "@patchConstantResult"
Name 135 "param"
Name 137 "param"
Name 142 "@patchConstantOutput.edges"
Name 155 "@patchConstantOutput.inside"
MemberDecorate 33(TessellationBuffer) 0 Offset 0
MemberDecorate 33(TessellationBuffer) 1 Offset 4
Decorate 33(TessellationBuffer) Block
Decorate 35 DescriptorSet 0
Decorate 35 Binding 0
Decorate 72(patch) Location 0
Decorate 76(pointId) BuiltIn InvocationId
Decorate 79(patchId) BuiltIn PrimitiveId
Decorate 83(@entryPointOutput) Location 0
Decorate 110(@patchConstantOutput.edges) Patch
Decorate 110(@patchConstantOutput.edges) BuiltIn TessLevelOuter
Decorate 123(@patchConstantOutput.inside) Patch
Decorate 123(@patchConstantOutput.inside) BuiltIn TessLevelInner
Decorate 73(patch.position) Location 0
Decorate 80(patch.color) Location 1
Decorate 99(pointId) BuiltIn InvocationId
Decorate 102(patchId) BuiltIn PrimitiveId
Decorate 113(@entryPointOutput.position) Location 0
Decorate 120(@entryPointOutput.color) Location 1
Decorate 142(@patchConstantOutput.edges) Patch
Decorate 142(@patchConstantOutput.edges) BuiltIn TessLevelOuter
Decorate 155(@patchConstantOutput.inside) Patch
Decorate 155(@patchConstantOutput.inside) BuiltIn TessLevelInner
2: TypeVoid
3: TypeFunction 2
6: TypeFloat 32
@ -448,83 +627,122 @@ triangle order = cw
55: TypePointer Function 22(HullOutputType)
58: TypePointer Function 7(fvec3)
63: TypePointer Function 8(fvec4)
71: TypePointer Input 12
72(patch): 71(ptr) Variable Input
75: TypePointer Input 10(int)
76(pointId): 75(ptr) Variable Input
79(patchId): 75(ptr) Variable Input
81: TypeArray 22(HullOutputType) 11
82: TypePointer Output 81
83(@entryPointOutput): 82(ptr) Variable Output
92: TypePointer Output 22(HullOutputType)
94: 10(int) Constant 2
95: 10(int) Constant 4
96: 10(int) Constant 0
98: TypeBool
108: TypeArray 6(float) 95
109: TypePointer Output 108
110(@patchConstantOutput.edges): 109(ptr) Variable Output
113: TypePointer Output 6(float)
121: TypeArray 6(float) 94
122: TypePointer Output 121
123(@patchConstantOutput.inside): 122(ptr) Variable Output
71: TypeArray 7(fvec3) 11
72: TypePointer Input 71
73(patch.position): 72(ptr) Variable Input
74: TypePointer Input 7(fvec3)
78: TypeArray 8(fvec4) 11
79: TypePointer Input 78
80(patch.color): 79(ptr) Variable Input
81: TypePointer Input 8(fvec4)
98: TypePointer Input 10(int)
99(pointId): 98(ptr) Variable Input
102(patchId): 98(ptr) Variable Input
112: TypePointer Output 71
113(@entryPointOutput.position): 112(ptr) Variable Output
117: TypePointer Output 7(fvec3)
119: TypePointer Output 78
120(@entryPointOutput.color): 119(ptr) Variable Output
124: TypePointer Output 8(fvec4)
126: 10(int) Constant 2
127: 10(int) Constant 4
128: 10(int) Constant 0
130: TypeBool
140: TypeArray 6(float) 127
141: TypePointer Output 140
142(@patchConstantOutput.edges): 141(ptr) Variable Output
145: TypePointer Output 6(float)
153: TypeArray 6(float) 126
154: TypePointer Output 153
155(@patchConstantOutput.inside): 154(ptr) Variable Output
4(main): 2 Function None 3
5: Label
70(patch): 13(ptr) Variable Function
74(pointId): 14(ptr) Variable Function
78(patchId): 14(ptr) Variable Function
85(param): 13(ptr) Variable Function
87(param): 14(ptr) Variable Function
89(param): 14(ptr) Variable Function
102(@patchConstantResult): 29(ptr) Variable Function
103(param): 13(ptr) Variable Function
105(param): 14(ptr) Variable Function
73: 12 Load 72(patch)
Store 70(patch) 73
77: 10(int) Load 76(pointId)
Store 74(pointId) 77
80: 10(int) Load 79(patchId)
Store 78(patchId) 80
84: 10(int) Load 76(pointId)
86: 12 Load 70(patch)
Store 85(param) 86
88: 10(int) Load 74(pointId)
Store 87(param) 88
90: 10(int) Load 78(patchId)
Store 89(param) 90
91:22(HullOutputType) FunctionCall 27(@main(struct-HullInputType-vf3-vf41[3];u1;u1;) 85(param) 87(param) 89(param)
93: 92(ptr) AccessChain 83(@entryPointOutput) 84
Store 93 91
ControlBarrier 94 95 96
97: 10(int) Load 76(pointId)
99: 98(bool) IEqual 97 32
SelectionMerge 101 None
BranchConditional 99 100 101
100: Label
104: 12 Load 70(patch)
Store 103(param) 104
106: 10(int) Load 79(patchId)
Store 105(param) 106
107:16(ConstantOutputType) FunctionCall 20(ColorPatchConstantFunction(struct-HullInputType-vf3-vf41[3];u1;) 103(param) 105(param)
Store 102(@patchConstantResult) 107
111: 39(ptr) AccessChain 102(@patchConstantResult) 32 32
112: 6(float) Load 111
114: 113(ptr) AccessChain 110(@patchConstantOutput.edges) 32
Store 114 112
115: 39(ptr) AccessChain 102(@patchConstantResult) 32 41
116: 6(float) Load 115
117: 113(ptr) AccessChain 110(@patchConstantOutput.edges) 41
Store 117 116
118: 39(ptr) AccessChain 102(@patchConstantResult) 32 45
119: 6(float) Load 118
120: 113(ptr) AccessChain 110(@patchConstantOutput.edges) 45
Store 120 119
124: 39(ptr) AccessChain 102(@patchConstantResult) 41
125: 6(float) Load 124
126: 113(ptr) AccessChain 123(@patchConstantOutput.inside) 32
Store 126 125
Branch 101
101: Label
97(pointId): 14(ptr) Variable Function
101(patchId): 14(ptr) Variable Function
104(flattenTemp): 55(ptr) Variable Function
105(param): 13(ptr) Variable Function
107(param): 14(ptr) Variable Function
109(param): 14(ptr) Variable Function
134(@patchConstantResult): 29(ptr) Variable Function
135(param): 13(ptr) Variable Function
137(param): 14(ptr) Variable Function
75: 74(ptr) AccessChain 73(patch.position) 32
76: 7(fvec3) Load 75
77: 58(ptr) AccessChain 70(patch) 32 32
Store 77 76
82: 81(ptr) AccessChain 80(patch.color) 32
83: 8(fvec4) Load 82
84: 63(ptr) AccessChain 70(patch) 32 41
Store 84 83
85: 74(ptr) AccessChain 73(patch.position) 41
86: 7(fvec3) Load 85
87: 58(ptr) AccessChain 70(patch) 41 32
Store 87 86
88: 81(ptr) AccessChain 80(patch.color) 41
89: 8(fvec4) Load 88
90: 63(ptr) AccessChain 70(patch) 41 41
Store 90 89
91: 74(ptr) AccessChain 73(patch.position) 45
92: 7(fvec3) Load 91
93: 58(ptr) AccessChain 70(patch) 45 32
Store 93 92
94: 81(ptr) AccessChain 80(patch.color) 45
95: 8(fvec4) Load 94
96: 63(ptr) AccessChain 70(patch) 45 41
Store 96 95
100: 10(int) Load 99(pointId)
Store 97(pointId) 100
103: 10(int) Load 102(patchId)
Store 101(patchId) 103
106: 12 Load 70(patch)
Store 105(param) 106
108: 10(int) Load 97(pointId)
Store 107(param) 108
110: 10(int) Load 101(patchId)
Store 109(param) 110
111:22(HullOutputType) FunctionCall 27(@main(struct-HullInputType-vf3-vf41[3];u1;u1;) 105(param) 107(param) 109(param)
Store 104(flattenTemp) 111
114: 10(int) Load 99(pointId)
115: 58(ptr) AccessChain 104(flattenTemp) 32
116: 7(fvec3) Load 115
118: 117(ptr) AccessChain 113(@entryPointOutput.position) 114
Store 118 116
121: 10(int) Load 99(pointId)
122: 63(ptr) AccessChain 104(flattenTemp) 41
123: 8(fvec4) Load 122
125: 124(ptr) AccessChain 120(@entryPointOutput.color) 121
Store 125 123
ControlBarrier 126 127 128
129: 10(int) Load 99(pointId)
131: 130(bool) IEqual 129 32
SelectionMerge 133 None
BranchConditional 131 132 133
132: Label
136: 12 Load 70(patch)
Store 135(param) 136
138: 10(int) Load 102(patchId)
Store 137(param) 138
139:16(ConstantOutputType) FunctionCall 20(ColorPatchConstantFunction(struct-HullInputType-vf3-vf41[3];u1;) 135(param) 137(param)
Store 134(@patchConstantResult) 139
143: 39(ptr) AccessChain 134(@patchConstantResult) 32 32
144: 6(float) Load 143
146: 145(ptr) AccessChain 142(@patchConstantOutput.edges) 32
Store 146 144
147: 39(ptr) AccessChain 134(@patchConstantResult) 32 41
148: 6(float) Load 147
149: 145(ptr) AccessChain 142(@patchConstantOutput.edges) 41
Store 149 148
150: 39(ptr) AccessChain 134(@patchConstantResult) 32 45
151: 6(float) Load 150
152: 145(ptr) AccessChain 142(@patchConstantOutput.edges) 45
Store 152 151
156: 39(ptr) AccessChain 134(@patchConstantResult) 41
157: 6(float) Load 156
158: 145(ptr) AccessChain 155(@patchConstantOutput.inside) 32
Store 158 157
Branch 133
133: Label
Return
FunctionEnd
20(ColorPatchConstantFunction(struct-HullInputType-vf3-vf41[3];u1;):16(ConstantOutputType) Function None 17