| 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 265 |
| |
| Capability Shader |
| 1: ExtInstImport "GLSL.std.450" |
| MemoryModel Logical GLSL450 |
| EntryPoint Fragment 4 "main" 73 223 |
| ExecutionMode 4 OriginLowerLeft |
| 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 58 "local" |
| Name 60 "c" |
| Name 71 "f" |
| Name 73 "x" |
| Name 127 "d" |
| Name 153 "i" |
| Name 172 "j" |
| Name 223 "color" |
| Name 229 "v" |
| Name 230 "param" |
| Name 232 "param" |
| Name 234 "param" |
| Name 242 "param" |
| Name 244 "param" |
| Name 246 "param" |
| Decorate 58(local) RelaxedPrecision |
| Decorate 60(c) RelaxedPrecision |
| Decorate 71(f) RelaxedPrecision |
| Decorate 73(x) RelaxedPrecision |
| Decorate 127(d) RelaxedPrecision |
| Decorate 153(i) RelaxedPrecision |
| Decorate 172(j) RelaxedPrecision |
| Decorate 223(color) RelaxedPrecision |
| Decorate 229(v) 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 |
| 47: 6(float) Constant 1065353216 |
| 48: 7(fvec4) ConstantComposite 47 47 47 47 |
| 59: TypePointer UniformConstant 9(int) |
| 60(c): 59(ptr) Variable UniformConstant |
| 63: 9(int) Constant 1 |
| 70: TypePointer Function 6(float) |
| 72: TypePointer Input 6(float) |
| 73(x): 72(ptr) Variable Input |
| 127(d): 59(ptr) Variable UniformConstant |
| 154: 9(int) Constant 0 |
| 160: 9(int) Constant 10 |
| 161: TypeBool |
| 173: 9(int) Constant 20 |
| 179: 9(int) Constant 30 |
| 184: 6(float) Constant 1120429670 |
| 204: 6(float) Constant 1079739679 |
| 222: TypePointer Output 6(float) |
| 223(color): 222(ptr) Variable Output |
| 228: TypePointer UniformConstant 7(fvec4) |
| 229(v): 228(ptr) Variable UniformConstant |
| 237: TypeInt 32 0 |
| 238: 237(int) Constant 1 |
| 249: 237(int) Constant 2 |
| 4(main): 2 Function None 3 |
| 5: Label |
| 58(local): 10(ptr) Variable Function |
| 71(f): 70(ptr) Variable Function |
| 153(i): 10(ptr) Variable Function |
| 172(j): 10(ptr) Variable Function |
| 230(param): 8(ptr) Variable Function |
| 232(param): 8(ptr) Variable Function |
| 234(param): 10(ptr) Variable Function |
| 242(param): 8(ptr) Variable Function |
| 244(param): 8(ptr) Variable Function |
| 246(param): 10(ptr) Variable Function |
| 61: 9(int) Load 60(c) |
| Store 58(local) 61 |
| 62: 9(int) Load 58(local) |
| 64: 9(int) IAdd 62 63 |
| Store 58(local) 64 |
| 65: 9(int) Load 60(c) |
| SelectionMerge 69 None |
| Switch 65 68 |
| case 1: 66 |
| case 2: 67 |
| 66: Label |
| 74: 6(float) Load 73(x) |
| 75: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 74 |
| Store 71(f) 75 |
| Branch 69 |
| 67: Label |
| 77: 6(float) Load 73(x) |
| 78: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 77 |
| Store 71(f) 78 |
| Branch 69 |
| 68: Label |
| 80: 6(float) Load 73(x) |
| 81: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 80 |
| Store 71(f) 81 |
| Branch 69 |
| 69: Label |
| 83: 9(int) Load 60(c) |
| SelectionMerge 87 None |
| Switch 83 86 |
| case 1: 84 |
| case 2: 85 |
| 84: Label |
| 88: 6(float) Load 73(x) |
| 89: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 88 |
| 90: 6(float) Load 71(f) |
| 91: 6(float) FAdd 90 89 |
| Store 71(f) 91 |
| Branch 85 |
| 85: Label |
| 92: 6(float) Load 73(x) |
| 93: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 92 |
| 94: 6(float) Load 71(f) |
| 95: 6(float) FAdd 94 93 |
| Store 71(f) 95 |
| Branch 87 |
| 86: Label |
| 97: 6(float) Load 73(x) |
| 98: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 97 |
| 99: 6(float) Load 71(f) |
| 100: 6(float) FAdd 99 98 |
| Store 71(f) 100 |
| Branch 87 |
| 87: Label |
| 102: 9(int) Load 60(c) |
| SelectionMerge 105 None |
| Switch 102 105 |
| case 1: 103 |
| case 2: 104 |
| 103: Label |
| 106: 6(float) Load 73(x) |
| 107: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 106 |
| 108: 6(float) Load 71(f) |
| 109: 6(float) FAdd 108 107 |
| Store 71(f) 109 |
| Branch 105 |
| 104: Label |
| 111: 6(float) Load 73(x) |
| 112: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 111 |
| 113: 6(float) Load 71(f) |
| 114: 6(float) FAdd 113 112 |
| Store 71(f) 114 |
| Branch 105 |
| 105: Label |
| 117: 9(int) Load 60(c) |
| SelectionMerge 121 None |
| Switch 117 120 |
| case 1: 118 |
| case 2: 119 |
| 118: Label |
| 122: 6(float) Load 73(x) |
| 123: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 122 |
| 124: 6(float) Load 71(f) |
| 125: 6(float) FAdd 124 123 |
| Store 71(f) 125 |
| Branch 121 |
| 119: Label |
| 128: 9(int) Load 127(d) |
| SelectionMerge 131 None |
| Switch 128 131 |
| case 1: 129 |
| case 2: 130 |
| 129: Label |
| 132: 6(float) Load 73(x) |
| 133: 6(float) Load 73(x) |
| 134: 6(float) FMul 132 133 |
| 135: 6(float) Load 73(x) |
| 136: 6(float) FMul 134 135 |
| 137: 6(float) Load 71(f) |
| 138: 6(float) FAdd 137 136 |
| Store 71(f) 138 |
| Branch 131 |
| 130: Label |
| 140: 6(float) Load 73(x) |
| 141: 6(float) Load 73(x) |
| 142: 6(float) FMul 140 141 |
| 143: 6(float) Load 71(f) |
| 144: 6(float) FAdd 143 142 |
| Store 71(f) 144 |
| Branch 131 |
| 131: Label |
| Branch 121 |
| 120: Label |
| 148: 6(float) Load 73(x) |
| 149: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 148 |
| 150: 6(float) Load 71(f) |
| 151: 6(float) FAdd 150 149 |
| Store 71(f) 151 |
| Branch 121 |
| 121: Label |
| Store 153(i) 154 |
| Branch 155 |
| 155: Label |
| 159: 9(int) Load 153(i) |
| 162: 161(bool) SLessThan 159 160 |
| LoopMerge 157 158 None |
| BranchConditional 162 156 157 |
| 156: Label |
| 163: 9(int) Load 60(c) |
| SelectionMerge 167 None |
| Switch 163 166 |
| case 1: 164 |
| case 2: 165 |
| 157: Label |
| 211: 9(int) Load 60(c) |
| SelectionMerge 214 None |
| Switch 211 214 |
| case 1: 212 |
| case 2: 213 |
| 158: Label |
| 209: 9(int) Load 153(i) |
| 210: 9(int) IAdd 209 63 |
| Store 153(i) 210 |
| Branch 155 |
| 164: Label |
| 168: 6(float) Load 73(x) |
| 169: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 168 |
| 170: 6(float) Load 71(f) |
| 171: 6(float) FAdd 170 169 |
| Store 71(f) 171 |
| Store 172(j) 173 |
| Branch 174 |
| 174: Label |
| 178: 9(int) Load 172(j) |
| 180: 161(bool) SLessThan 178 179 |
| LoopMerge 176 177 None |
| BranchConditional 180 175 176 |
| 175: Label |
| 181: 6(float) Load 71(f) |
| 182: 6(float) FAdd 181 47 |
| Store 71(f) 182 |
| 183: 6(float) Load 71(f) |
| 185: 161(bool) FOrdLessThan 183 184 |
| SelectionMerge 187 None |
| BranchConditional 185 186 187 |
| 176: Label |
| Branch 167 |
| 177: Label |
| 189: 9(int) Load 172(j) |
| 190: 9(int) IAdd 189 63 |
| Store 172(j) 190 |
| Branch 174 |
| 186: Label |
| Branch 176 |
| 187: Label |
| Branch 177 |
| 165: Label |
| 192: 6(float) Load 73(x) |
| 193: 6(float) ExtInst 1(GLSL.std.450) 14(Cos) 192 |
| 194: 6(float) Load 71(f) |
| 195: 6(float) FAdd 194 193 |
| Store 71(f) 195 |
| Branch 167 |
| 166: Label |
| 198: 6(float) Load 73(x) |
| 199: 6(float) ExtInst 1(GLSL.std.450) 15(Tan) 198 |
| 200: 6(float) Load 71(f) |
| 201: 6(float) FAdd 200 199 |
| Store 71(f) 201 |
| Branch 167 |
| 167: Label |
| 203: 6(float) Load 71(f) |
| 205: 161(bool) FOrdLessThan 203 204 |
| SelectionMerge 207 None |
| BranchConditional 205 206 207 |
| 206: Label |
| Branch 157 |
| 207: Label |
| Branch 158 |
| 212: Label |
| 215: 6(float) Load 73(x) |
| 216: 6(float) ExtInst 1(GLSL.std.450) 13(Sin) 215 |
| 217: 6(float) Load 71(f) |
| 218: 6(float) FAdd 217 216 |
| Store 71(f) 218 |
| Branch 214 |
| 213: Label |
| Branch 214 |
| 214: Label |
| 224: 6(float) Load 71(f) |
| 225: 9(int) Load 58(local) |
| 226: 6(float) ConvertSToF 225 |
| 227: 6(float) FAdd 224 226 |
| Store 223(color) 227 |
| 231: 7(fvec4) Load 229(v) |
| Store 230(param) 231 |
| 233: 7(fvec4) Load 229(v) |
| Store 232(param) 233 |
| 235: 9(int) Load 60(c) |
| Store 234(param) 235 |
| 236: 7(fvec4) FunctionCall 15(foo1(vf4;vf4;i1;) 230(param) 232(param) 234(param) |
| 239: 6(float) CompositeExtract 236 1 |
| 240: 6(float) Load 223(color) |
| 241: 6(float) FAdd 240 239 |
| Store 223(color) 241 |
| 243: 7(fvec4) Load 229(v) |
| Store 242(param) 243 |
| 245: 7(fvec4) Load 229(v) |
| Store 244(param) 245 |
| 247: 9(int) Load 60(c) |
| Store 246(param) 247 |
| 248: 7(fvec4) FunctionCall 20(foo2(vf4;vf4;i1;) 242(param) 244(param) 246(param) |
| 250: 6(float) CompositeExtract 248 2 |
| 251: 6(float) Load 223(color) |
| 252: 6(float) FAdd 251 250 |
| Store 223(color) 252 |
| 253: 9(int) Load 60(c) |
| SelectionMerge 256 None |
| Switch 253 255 |
| case 0: 254 |
| 254: Label |
| Branch 256 |
| 255: Label |
| Branch 256 |
| 256: Label |
| 260: 9(int) Load 60(c) |
| SelectionMerge 262 None |
| Switch 260 261 |
| 261: Label |
| Branch 262 |
| 262: 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 |
| 39: 9(int) Load 19(i1) |
| SelectionMerge 44 None |
| Switch 39 44 |
| case 0: 40 |
| case 2: 41 |
| case 1: 42 |
| case 3: 43 |
| 40: Label |
| 45: 7(fvec4) Load 17(v1) |
| ReturnValue 45 |
| 41: Label |
| ReturnValue 48 |
| 42: Label |
| 50: 7(fvec4) Load 18(v2) |
| ReturnValue 50 |
| 43: Label |
| 52: 7(fvec4) Load 17(v1) |
| 53: 7(fvec4) Load 18(v2) |
| 54: 7(fvec4) FMul 52 53 |
| ReturnValue 54 |
| 44: Label |
| ReturnValue 37 |
| FunctionEnd |