blob: 87ea4c87ea7caf7895026d20b8254eb4fdf30eaf [file] [log] [blame]
spv.switch.frag
Warning, version 310 is not yet complete; most version-specific features are present, but some are missing.
WARNING: 0:121: 'switch' : last case/default label not followed by statements
WARNING: 0:134: 'switch' : last case/default label not followed by statements
WARNING: 0:139: 'switch' : last case/default label not followed by statements
Linked fragment stage:
// Module Version 10000
// Generated by (magic number): 80001
// Id's are bound by 269
Capability Shader
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint Fragment 4 "main" 62 75 129 227 233
ExecutionMode 4 OriginUpperLeft
Source ESSL 310
Name 4 "main"
Name 15 "foo1(vf4;vf4;i1;"
Name 12 "v1"
Name 13 "v2"
Name 14 "i1"
Name 20 "foo2(vf4;vf4;i1;"
Name 17 "v1"
Name 18 "v2"
Name 19 "i1"
Name 60 "local"
Name 62 "c"
Name 73 "f"
Name 75 "x"
Name 129 "d"
Name 155 "i"
Name 175 "j"
Name 227 "color"
Name 233 "v"
Name 234 "param"
Name 236 "param"
Name 238 "param"
Name 246 "param"
Name 248 "param"
Name 250 "param"
Decorate 15(foo1(vf4;vf4;i1;) RelaxedPrecision
Decorate 12(v1) RelaxedPrecision
Decorate 13(v2) RelaxedPrecision
Decorate 14(i1) RelaxedPrecision
Decorate 20(foo2(vf4;vf4;i1;) RelaxedPrecision
Decorate 17(v1) RelaxedPrecision
Decorate 18(v2) RelaxedPrecision
Decorate 19(i1) RelaxedPrecision
Decorate 22 RelaxedPrecision
Decorate 27 RelaxedPrecision
Decorate 29 RelaxedPrecision
Decorate 31 RelaxedPrecision
Decorate 32 RelaxedPrecision
Decorate 33 RelaxedPrecision
Decorate 40 RelaxedPrecision
Decorate 46 RelaxedPrecision
Decorate 51 RelaxedPrecision
Decorate 53 RelaxedPrecision
Decorate 54 RelaxedPrecision
Decorate 55 RelaxedPrecision
Decorate 60(local) RelaxedPrecision
Decorate 62(c) RelaxedPrecision
Decorate 62(c) Flat
Decorate 63 RelaxedPrecision
Decorate 64 RelaxedPrecision
Decorate 66 RelaxedPrecision
Decorate 67 RelaxedPrecision
Decorate 73(f) RelaxedPrecision
Decorate 75(x) RelaxedPrecision
Decorate 76 RelaxedPrecision
Decorate 77 RelaxedPrecision
Decorate 79 RelaxedPrecision
Decorate 80 RelaxedPrecision
Decorate 82 RelaxedPrecision
Decorate 83 RelaxedPrecision
Decorate 85 RelaxedPrecision
Decorate 90 RelaxedPrecision
Decorate 91 RelaxedPrecision
Decorate 92 RelaxedPrecision
Decorate 93 RelaxedPrecision
Decorate 94 RelaxedPrecision
Decorate 95 RelaxedPrecision
Decorate 96 RelaxedPrecision
Decorate 97 RelaxedPrecision
Decorate 99 RelaxedPrecision
Decorate 100 RelaxedPrecision
Decorate 101 RelaxedPrecision
Decorate 102 RelaxedPrecision
Decorate 104 RelaxedPrecision
Decorate 108 RelaxedPrecision
Decorate 109 RelaxedPrecision
Decorate 110 RelaxedPrecision
Decorate 111 RelaxedPrecision
Decorate 113 RelaxedPrecision
Decorate 114 RelaxedPrecision
Decorate 115 RelaxedPrecision
Decorate 116 RelaxedPrecision
Decorate 119 RelaxedPrecision
Decorate 124 RelaxedPrecision
Decorate 125 RelaxedPrecision
Decorate 126 RelaxedPrecision
Decorate 127 RelaxedPrecision
Decorate 129(d) RelaxedPrecision
Decorate 129(d) Flat
Decorate 130 RelaxedPrecision
Decorate 134 RelaxedPrecision
Decorate 135 RelaxedPrecision
Decorate 136 RelaxedPrecision
Decorate 137 RelaxedPrecision
Decorate 138 RelaxedPrecision
Decorate 139 RelaxedPrecision
Decorate 140 RelaxedPrecision
Decorate 142 RelaxedPrecision
Decorate 143 RelaxedPrecision
Decorate 144 RelaxedPrecision
Decorate 145 RelaxedPrecision
Decorate 146 RelaxedPrecision
Decorate 150 RelaxedPrecision
Decorate 151 RelaxedPrecision
Decorate 152 RelaxedPrecision
Decorate 153 RelaxedPrecision
Decorate 155(i) RelaxedPrecision
Decorate 162 RelaxedPrecision
Decorate 166 RelaxedPrecision
Decorate 171 RelaxedPrecision
Decorate 172 RelaxedPrecision
Decorate 173 RelaxedPrecision
Decorate 174 RelaxedPrecision
Decorate 175(j) RelaxedPrecision
Decorate 182 RelaxedPrecision
Decorate 185 RelaxedPrecision
Decorate 186 RelaxedPrecision
Decorate 187 RelaxedPrecision
Decorate 193 RelaxedPrecision
Decorate 194 RelaxedPrecision
Decorate 196 RelaxedPrecision
Decorate 197 RelaxedPrecision
Decorate 198 RelaxedPrecision
Decorate 199 RelaxedPrecision
Decorate 202 RelaxedPrecision
Decorate 203 RelaxedPrecision
Decorate 204 RelaxedPrecision
Decorate 205 RelaxedPrecision
Decorate 207 RelaxedPrecision
Decorate 213 RelaxedPrecision
Decorate 214 RelaxedPrecision
Decorate 215 RelaxedPrecision
Decorate 219 RelaxedPrecision
Decorate 220 RelaxedPrecision
Decorate 221 RelaxedPrecision
Decorate 222 RelaxedPrecision
Decorate 227(color) RelaxedPrecision
Decorate 228 RelaxedPrecision
Decorate 229 RelaxedPrecision
Decorate 230 RelaxedPrecision
Decorate 231 RelaxedPrecision
Decorate 233(v) RelaxedPrecision
Decorate 235 RelaxedPrecision
Decorate 237 RelaxedPrecision
Decorate 239 RelaxedPrecision
Decorate 240 RelaxedPrecision
Decorate 243 RelaxedPrecision
Decorate 244 RelaxedPrecision
Decorate 245 RelaxedPrecision
Decorate 247 RelaxedPrecision
Decorate 249 RelaxedPrecision
Decorate 251 RelaxedPrecision
Decorate 252 RelaxedPrecision
Decorate 254 RelaxedPrecision
Decorate 255 RelaxedPrecision
Decorate 256 RelaxedPrecision
Decorate 257 RelaxedPrecision
Decorate 264 RelaxedPrecision
2: TypeVoid
3: TypeFunction 2
6: TypeFloat 32
7: TypeVector 6(float) 4
8: TypePointer Function 7(fvec4)
9: TypeInt 32 1
10: TypePointer Function 9(int)
11: TypeFunction 7(fvec4) 8(ptr) 8(ptr) 10(ptr)
36: 6(float) Constant 0
37: 7(fvec4) ConstantComposite 36 36 36 36
48: 6(float) Constant 1065353216
49: 7(fvec4) ConstantComposite 48 48 48 48
61: TypePointer Input 9(int)
62(c): 61(ptr) Variable Input
65: 9(int) Constant 1
72: TypePointer Function 6(float)
74: TypePointer Input 6(float)
75(x): 74(ptr) Variable Input
129(d): 61(ptr) Variable Input
156: 9(int) Constant 0
163: 9(int) Constant 10
164: TypeBool
176: 9(int) Constant 20
183: 9(int) Constant 30
188: 6(float) Constant 1120429670
208: 6(float) Constant 1079739679
226: TypePointer Output 6(float)
227(color): 226(ptr) Variable Output
232: TypePointer Input 7(fvec4)
233(v): 232(ptr) Variable Input
241: TypeInt 32 0
242: 241(int) Constant 1
253: 241(int) Constant 2
4(main): 2 Function None 3
5: Label
60(local): 10(ptr) Variable Function
73(f): 72(ptr) Variable Function
155(i): 10(ptr) Variable Function
175(j): 10(ptr) Variable Function
234(param): 8(ptr) Variable Function
236(param): 8(ptr) Variable Function
238(param): 10(ptr) Variable Function
246(param): 8(ptr) Variable Function
248(param): 8(ptr) Variable Function
250(param): 10(ptr) Variable Function
63: 9(int) Load 62(c)
Store 60(local) 63
64: 9(int) Load 60(local)
66: 9(int) IAdd 64 65
Store 60(local) 66
67: 9(int) Load 62(c)
SelectionMerge 71 None
Switch 67 70
case 1: 68
case 2: 69
70: Label
82: 6(float) Load 75(x)
83: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 82
Store 73(f) 83
Branch 71
68: Label
76: 6(float) Load 75(x)
77: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 76
Store 73(f) 77
Branch 71
69: Label
79: 6(float) Load 75(x)
80: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 79
Store 73(f) 80
Branch 71
71: Label
85: 9(int) Load 62(c)
SelectionMerge 89 None
Switch 85 88
case 1: 86
case 2: 87
88: Label
99: 6(float) Load 75(x)
100: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 99
101: 6(float) Load 73(f)
102: 6(float) FAdd 101 100
Store 73(f) 102
Branch 89
86: Label
90: 6(float) Load 75(x)
91: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 90
92: 6(float) Load 73(f)
93: 6(float) FAdd 92 91
Store 73(f) 93
Branch 87
87: Label
94: 6(float) Load 75(x)
95: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 94
96: 6(float) Load 73(f)
97: 6(float) FAdd 96 95
Store 73(f) 97
Branch 89
89: Label
104: 9(int) Load 62(c)
SelectionMerge 107 None
Switch 104 107
case 1: 105
case 2: 106
105: Label
108: 6(float) Load 75(x)
109: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 108
110: 6(float) Load 73(f)
111: 6(float) FAdd 110 109
Store 73(f) 111
Branch 107
106: Label
113: 6(float) Load 75(x)
114: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 113
115: 6(float) Load 73(f)
116: 6(float) FAdd 115 114
Store 73(f) 116
Branch 107
107: Label
119: 9(int) Load 62(c)
SelectionMerge 123 None
Switch 119 122
case 1: 120
case 2: 121
122: Label
150: 6(float) Load 75(x)
151: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 150
152: 6(float) Load 73(f)
153: 6(float) FAdd 152 151
Store 73(f) 153
Branch 123
120: Label
124: 6(float) Load 75(x)
125: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 124
126: 6(float) Load 73(f)
127: 6(float) FAdd 126 125
Store 73(f) 127
Branch 123
121: Label
130: 9(int) Load 129(d)
SelectionMerge 133 None
Switch 130 133
case 1: 131
case 2: 132
131: Label
134: 6(float) Load 75(x)
135: 6(float) Load 75(x)
136: 6(float) FMul 134 135
137: 6(float) Load 75(x)
138: 6(float) FMul 136 137
139: 6(float) Load 73(f)
140: 6(float) FAdd 139 138
Store 73(f) 140
Branch 133
132: Label
142: 6(float) Load 75(x)
143: 6(float) Load 75(x)
144: 6(float) FMul 142 143
145: 6(float) Load 73(f)
146: 6(float) FAdd 145 144
Store 73(f) 146
Branch 133
133: Label
Branch 123
123: Label
Store 155(i) 156
Branch 157
157: Label
LoopMerge 159 160 None
Branch 161
161: Label
162: 9(int) Load 155(i)
165: 164(bool) SLessThan 162 163
BranchConditional 165 158 159
158: Label
166: 9(int) Load 62(c)
SelectionMerge 170 None
Switch 166 169
case 1: 167
case 2: 168
169: Label
202: 6(float) Load 75(x)
203: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 202
204: 6(float) Load 73(f)
205: 6(float) FAdd 204 203
Store 73(f) 205
Branch 170
167: Label
171: 6(float) Load 75(x)
172: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 171
173: 6(float) Load 73(f)
174: 6(float) FAdd 173 172
Store 73(f) 174
Store 175(j) 176
Branch 177
177: Label
LoopMerge 179 180 None
Branch 181
181: Label
182: 9(int) Load 175(j)
184: 164(bool) SLessThan 182 183
BranchConditional 184 178 179
178: Label
185: 6(float) Load 73(f)
186: 6(float) FAdd 185 48
Store 73(f) 186
187: 6(float) Load 73(f)
189: 164(bool) FOrdLessThan 187 188
SelectionMerge 191 None
BranchConditional 189 190 191
190: Label
Branch 179
191: Label
Branch 180
180: Label
193: 9(int) Load 175(j)
194: 9(int) IAdd 193 65
Store 175(j) 194
Branch 177
179: Label
Branch 170
168: Label
196: 6(float) Load 75(x)
197: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 196
198: 6(float) Load 73(f)
199: 6(float) FAdd 198 197
Store 73(f) 199
Branch 170
170: Label
207: 6(float) Load 73(f)
209: 164(bool) FOrdLessThan 207 208
SelectionMerge 211 None
BranchConditional 209 210 211
210: Label
Branch 159
211: Label
Branch 160
160: Label
213: 9(int) Load 155(i)
214: 9(int) IAdd 213 65
Store 155(i) 214
Branch 157
159: Label
215: 9(int) Load 62(c)
SelectionMerge 218 None
Switch 215 218
case 1: 216
case 2: 217
216: Label
219: 6(float) Load 75(x)
220: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 219
221: 6(float) Load 73(f)
222: 6(float) FAdd 221 220
Store 73(f) 222
Branch 218
217: Label
Branch 218
218: Label
228: 6(float) Load 73(f)
229: 9(int) Load 60(local)
230: 6(float) ConvertSToF 229
231: 6(float) FAdd 228 230
Store 227(color) 231
235: 7(fvec4) Load 233(v)
Store 234(param) 235
237: 7(fvec4) Load 233(v)
Store 236(param) 237
239: 9(int) Load 62(c)
Store 238(param) 239
240: 7(fvec4) FunctionCall 15(foo1(vf4;vf4;i1;) 234(param) 236(param) 238(param)
243: 6(float) CompositeExtract 240 1
244: 6(float) Load 227(color)
245: 6(float) FAdd 244 243
Store 227(color) 245
247: 7(fvec4) Load 233(v)
Store 246(param) 247
249: 7(fvec4) Load 233(v)
Store 248(param) 249
251: 9(int) Load 62(c)
Store 250(param) 251
252: 7(fvec4) FunctionCall 20(foo2(vf4;vf4;i1;) 246(param) 248(param) 250(param)
254: 6(float) CompositeExtract 252 2
255: 6(float) Load 227(color)
256: 6(float) FAdd 255 254
Store 227(color) 256
257: 9(int) Load 62(c)
SelectionMerge 260 None
Switch 257 259
case 0: 258
259: Label
Branch 260
258: Label
Branch 260
260: Label
264: 9(int) Load 62(c)
SelectionMerge 266 None
Switch 264 265
265: Label
Branch 266
266: Label
Return
FunctionEnd
15(foo1(vf4;vf4;i1;): 7(fvec4) Function None 11
12(v1): 8(ptr) FunctionParameter
13(v2): 8(ptr) FunctionParameter
14(i1): 10(ptr) FunctionParameter
16: Label
22: 9(int) Load 14(i1)
SelectionMerge 26 None
Switch 22 26
case 0: 23
case 2: 24
case 1: 24
case 3: 25
23: Label
27: 7(fvec4) Load 12(v1)
ReturnValue 27
24: Label
29: 7(fvec4) Load 13(v2)
ReturnValue 29
25: Label
31: 7(fvec4) Load 12(v1)
32: 7(fvec4) Load 13(v2)
33: 7(fvec4) FMul 31 32
ReturnValue 33
26: Label
ReturnValue 37
FunctionEnd
20(foo2(vf4;vf4;i1;): 7(fvec4) Function None 11
17(v1): 8(ptr) FunctionParameter
18(v2): 8(ptr) FunctionParameter
19(i1): 10(ptr) FunctionParameter
21: Label
40: 9(int) Load 19(i1)
SelectionMerge 45 None
Switch 40 45
case 0: 41
case 2: 42
case 1: 43
case 3: 44
41: Label
46: 7(fvec4) Load 17(v1)
ReturnValue 46
42: Label
ReturnValue 49
43: Label
51: 7(fvec4) Load 18(v2)
ReturnValue 51
44: Label
53: 7(fvec4) Load 17(v1)
54: 7(fvec4) Load 18(v2)
55: 7(fvec4) FMul 53 54
ReturnValue 55
45: Label
ReturnValue 37
FunctionEnd