blob: e491eec9cfdab9c3a4fa07d930a5f1162bd1111c [file] [log] [blame]
SKIP: FAILED
../../src/tint/lang/msl/writer/printer/printer.cc:500 internal compiler error: strided_arr = struct @align(4) {
el:i32 @offset(0)
}
buf0 = struct @align(4) {
x_GLF_uniform_int_values:array<strided_arr, 20> @offset(0)
}
buf1 = struct @align(4) {
one:i32 @offset(0)
}
main_out = struct @align(16) {
x_GLF_color_1:vec4<f32> @offset(0), @location(0)
}
$B1: { # root
%x_6:ptr<uniform, buf0, read> = var @binding_point(0, 0)
%x_GLF_color:ptr<private, vec4<f32>, read_write> = var
%x_19:ptr<uniform, buf1, read> = var @binding_point(0, 1)
}
%main_1 = func():void {
$B2: {
%arr0:ptr<function, array<i32, 10>, read_write> = var
%arr1:ptr<function, array<i32, 10>, read_write> = var
%a:ptr<function, i32, read_write> = var
%limiter0:ptr<function, i32, read_write> = var
%limiter1:ptr<function, i32, read_write> = var
%b:ptr<function, i32, read_write> = var
%limiter2:ptr<function, i32, read_write> = var
%limiter3:ptr<function, i32, read_write> = var
%d:ptr<function, i32, read_write> = var
%ref0:ptr<function, array<i32, 10>, read_write> = var
%ref1:ptr<function, array<i32, 10>, read_write> = var
%i:ptr<function, i32, read_write> = var
%17:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%18:i32 = load %17
%x_59:i32 = let %18
%20:ptr<uniform, i32, read> = access %x_6, 0u, 2i, 0u
%21:i32 = load %20
%x_61:i32 = let %21
%23:ptr<uniform, i32, read> = access %x_6, 0u, 4i, 0u
%24:i32 = load %23
%x_63:i32 = let %24
%26:ptr<uniform, i32, read> = access %x_6, 0u, 5i, 0u
%27:i32 = load %26
%x_65:i32 = let %27
%29:ptr<uniform, i32, read> = access %x_6, 0u, 6i, 0u
%30:i32 = load %29
%x_67:i32 = let %30
%32:ptr<uniform, i32, read> = access %x_6, 0u, 7i, 0u
%33:i32 = load %32
%x_69:i32 = let %33
%35:ptr<uniform, i32, read> = access %x_6, 0u, 8i, 0u
%36:i32 = load %35
%x_71:i32 = let %36
%38:ptr<uniform, i32, read> = access %x_6, 0u, 9i, 0u
%39:i32 = load %38
%x_73:i32 = let %39
%41:ptr<uniform, i32, read> = access %x_6, 0u, 0i, 0u
%42:i32 = load %41
%x_75:i32 = let %42
%44:ptr<uniform, i32, read> = access %x_6, 0u, 10i, 0u
%45:i32 = load %44
%x_77:i32 = let %45
%47:array<i32, 10> = construct %x_59, %x_61, %x_63, %x_65, %x_67, %x_69, %x_71, %x_73, %x_75, %x_77
store %arr0, %47
%48:ptr<uniform, i32, read> = access %x_6, 0u, 1i, 0u
%49:i32 = load %48
%x_80:i32 = let %49
%51:ptr<uniform, i32, read> = access %x_6, 0u, 12i, 0u
%52:i32 = load %51
%x_82:i32 = let %52
%54:ptr<uniform, i32, read> = access %x_6, 0u, 15i, 0u
%55:i32 = load %54
%x_84:i32 = let %55
%57:ptr<uniform, i32, read> = access %x_6, 0u, 16i, 0u
%58:i32 = load %57
%x_86:i32 = let %58
%60:ptr<uniform, i32, read> = access %x_6, 0u, 17i, 0u
%61:i32 = load %60
%x_88:i32 = let %61
%63:ptr<uniform, i32, read> = access %x_6, 0u, 13i, 0u
%64:i32 = load %63
%x_90:i32 = let %64
%66:ptr<uniform, i32, read> = access %x_6, 0u, 14i, 0u
%67:i32 = load %66
%x_92:i32 = let %67
%69:ptr<uniform, i32, read> = access %x_6, 0u, 11i, 0u
%70:i32 = load %69
%x_94:i32 = let %70
%72:ptr<uniform, i32, read> = access %x_6, 0u, 18i, 0u
%73:i32 = load %72
%x_96:i32 = let %73
%75:ptr<uniform, i32, read> = access %x_6, 0u, 19i, 0u
%76:i32 = load %75
%x_98:i32 = let %76
%78:array<i32, 10> = construct %x_80, %x_82, %x_84, %x_86, %x_88, %x_90, %x_92, %x_94, %x_96, %x_98
store %arr1, %78
%79:ptr<uniform, i32, read> = access %x_6, 0u, 8i, 0u
%80:i32 = load %79
%x_101:i32 = let %80
store %a, %x_101
loop [b: $B3, c: $B4] { # loop_1
$B3: { # body
%82:i32 = load %a
%x_106:i32 = let %82
%84:ptr<uniform, i32, read> = access %x_6, 0u, 0i, 0u
%85:i32 = load %84
%x_108:i32 = let %85
%87:bool = lt %x_106, %x_108
if %87 [t: $B5, f: $B6] { # if_1
$B5: { # true
exit_if # if_1
}
$B6: { # false
exit_loop # loop_1
}
}
%88:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%89:i32 = load %88
%x_112:i32 = let %89
store %limiter0, %x_112
loop [b: $B7, c: $B8] { # loop_2
$B7: { # body
%91:i32 = load %limiter0
%x_117:i32 = let %91
%93:ptr<uniform, i32, read> = access %x_6, 0u, 4i, 0u
%94:i32 = load %93
%x_119:i32 = let %94
%96:bool = lt %x_117, %x_119
if %96 [t: $B9, f: $B10] { # if_2
$B9: { # true
exit_if # if_2
}
$B10: { # false
exit_loop # loop_2
}
}
%97:i32 = load %limiter0
%x_122:i32 = let %97
%99:i32 = add %x_122, 1i
store %limiter0, %99
%100:ptr<uniform, i32, read> = access %x_6, 0u, 2i, 0u
%101:i32 = load %100
%x_125:i32 = let %101
store %limiter1, %x_125
%103:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%104:i32 = load %103
%x_127:i32 = let %104
store %b, %x_127
loop [b: $B11, c: $B12] { # loop_3
$B11: { # body
%106:i32 = load %b
%x_132:i32 = let %106
%108:ptr<uniform, i32, read> = access %x_6, 0u, 1i, 0u
%109:i32 = load %108
%x_134:i32 = let %109
%111:bool = lt %x_132, %x_134
if %111 [t: $B13, f: $B14] { # if_3
$B13: { # true
exit_if # if_3
}
$B14: { # false
exit_loop # loop_3
}
}
%112:i32 = load %limiter1
%x_137:i32 = let %112
%114:ptr<uniform, i32, read> = access %x_6, 0u, 5i, 0u
%115:i32 = load %114
%x_139:i32 = let %115
%117:bool = gt %x_137, %x_139
if %117 [t: $B15] { # if_4
$B15: { # true
exit_loop # loop_3
}
}
%118:i32 = load %limiter1
%x_143:i32 = let %118
%120:i32 = add %x_143, 1i
store %limiter1, %120
%121:i32 = load %b
%x_145:i32 = let %121
%123:i32 = load %a
%x_146:i32 = let %123
%125:ptr<function, i32, read_write> = access %arr1, %x_146
%126:i32 = load %125
%x_148:i32 = let %126
%128:ptr<function, i32, read_write> = access %arr0, %x_145
store %128, %x_148
continue # -> $B12
}
$B12: { # continuing
%129:i32 = load %b
%x_150:i32 = let %129
%131:i32 = add %x_150, 1i
store %b, %131
next_iteration # -> $B11
}
}
continue # -> $B8
}
$B8: { # continuing
next_iteration # -> $B7
}
}
store %limiter2, 0i
loop [b: $B16, c: $B17] { # loop_4
$B16: { # body
%132:i32 = load %limiter2
%x_156:i32 = let %132
%134:bool = lt %x_156, 5i
if %134 [t: $B18, f: $B19] { # if_5
$B18: { # true
exit_if # if_5
}
$B19: { # false
exit_loop # loop_4
}
}
%135:i32 = load %limiter2
%x_159:i32 = let %135
%137:i32 = add %x_159, 1i
store %limiter2, %137
%138:ptr<function, i32, read_write> = access %arr1, 1i
%139:i32 = load %138
%x_162:i32 = let %139
%141:ptr<function, i32, read_write> = access %arr0, 1i
store %141, %x_162
continue # -> $B17
}
$B17: { # continuing
next_iteration # -> $B16
}
}
loop [b: $B20, c: $B21] { # loop_5
$B20: { # body
store %limiter3, 0i
store %d, 0i
loop [b: $B22, c: $B23] { # loop_6
$B22: { # body
%142:i32 = load %d
%x_172:i32 = let %142
%144:bool = lt %x_172, 10i
if %144 [t: $B24, f: $B25] { # if_6
$B24: { # true
exit_if # if_6
}
$B25: { # false
exit_loop # loop_6
}
}
%145:i32 = load %limiter3
%x_175:i32 = let %145
%147:bool = gt %x_175, 4i
if %147 [t: $B26] { # if_7
$B26: { # true
exit_loop # loop_6
}
}
%148:i32 = load %limiter3
%x_179:i32 = let %148
%150:i32 = add %x_179, 1i
store %limiter3, %150
%151:i32 = load %d
%x_181:i32 = let %151
%153:i32 = load %d
%x_182:i32 = let %153
%155:ptr<function, i32, read_write> = access %arr0, %x_182
%156:i32 = load %155
%x_184:i32 = let %156
%158:ptr<function, i32, read_write> = access %arr1, %x_181
store %158, %x_184
continue # -> $B23
}
$B23: { # continuing
%159:i32 = load %d
%x_186:i32 = let %159
%161:i32 = add %x_186, 1i
store %d, %161
next_iteration # -> $B22
}
}
continue # -> $B21
}
$B21: { # continuing
%162:ptr<uniform, i32, read> = access %x_6, 0u, 2i, 0u
%163:i32 = load %162
%x_189:i32 = let %163
%165:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%166:i32 = load %165
%x_191:i32 = let %166
%168:bool = eq %x_189, %x_191
%169:bool = eq %168, false
break_if %169 # -> [t: exit_loop loop_5, f: $B20]
}
}
continue # -> $B4
}
$B4: { # continuing
%170:i32 = load %a
%x_193:i32 = let %170
%172:i32 = add %x_193, 1i
store %a, %172
next_iteration # -> $B3
}
}
%173:ptr<uniform, i32, read> = access %x_6, 0u, 11i, 0u
%174:i32 = load %173
%x_196:i32 = let %174
%176:ptr<uniform, i32, read> = access %x_6, 0u, 12i, 0u
%177:i32 = load %176
%x_198:i32 = let %177
%179:ptr<uniform, i32, read> = access %x_6, 0u, 11i, 0u
%180:i32 = load %179
%x_200:i32 = let %180
%182:ptr<uniform, i32, read> = access %x_6, 0u, 5i, 0u
%183:i32 = load %182
%x_202:i32 = let %183
%185:ptr<uniform, i32, read> = access %x_6, 0u, 6i, 0u
%186:i32 = load %185
%x_204:i32 = let %186
%188:ptr<uniform, i32, read> = access %x_6, 0u, 7i, 0u
%189:i32 = load %188
%x_206:i32 = let %189
%191:ptr<uniform, i32, read> = access %x_6, 0u, 8i, 0u
%192:i32 = load %191
%x_208:i32 = let %192
%194:ptr<uniform, i32, read> = access %x_6, 0u, 9i, 0u
%195:i32 = load %194
%x_210:i32 = let %195
%197:ptr<uniform, i32, read> = access %x_6, 0u, 0i, 0u
%198:i32 = load %197
%x_212:i32 = let %198
%200:ptr<uniform, i32, read> = access %x_6, 0u, 10i, 0u
%201:i32 = load %200
%x_214:i32 = let %201
%203:array<i32, 10> = construct %x_196, %x_198, %x_200, %x_202, %x_204, %x_206, %x_208, %x_210, %x_212, %x_214
store %ref0, %203
%204:ptr<uniform, i32, read> = access %x_6, 0u, 11i, 0u
%205:i32 = load %204
%x_217:i32 = let %205
%207:ptr<uniform, i32, read> = access %x_6, 0u, 12i, 0u
%208:i32 = load %207
%x_219:i32 = let %208
%210:ptr<uniform, i32, read> = access %x_6, 0u, 11i, 0u
%211:i32 = load %210
%x_221:i32 = let %211
%213:ptr<uniform, i32, read> = access %x_6, 0u, 5i, 0u
%214:i32 = load %213
%x_223:i32 = let %214
%216:ptr<uniform, i32, read> = access %x_6, 0u, 6i, 0u
%217:i32 = load %216
%x_225:i32 = let %217
%219:ptr<uniform, i32, read> = access %x_6, 0u, 13i, 0u
%220:i32 = load %219
%x_227:i32 = let %220
%222:ptr<uniform, i32, read> = access %x_6, 0u, 14i, 0u
%223:i32 = load %222
%x_229:i32 = let %223
%225:ptr<uniform, i32, read> = access %x_6, 0u, 11i, 0u
%226:i32 = load %225
%x_231:i32 = let %226
%228:ptr<uniform, i32, read> = access %x_6, 0u, 18i, 0u
%229:i32 = load %228
%x_233:i32 = let %229
%231:ptr<uniform, i32, read> = access %x_6, 0u, 19i, 0u
%232:i32 = load %231
%x_235:i32 = let %232
%234:array<i32, 10> = construct %x_217, %x_219, %x_221, %x_223, %x_225, %x_227, %x_229, %x_231, %x_233, %x_235
store %ref1, %234
%235:ptr<uniform, i32, read> = access %x_6, 0u, 2i, 0u
%236:i32 = load %235
%x_238:i32 = let %236
%238:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%239:i32 = load %238
%x_241:i32 = let %239
%241:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%242:i32 = load %241
%x_244:i32 = let %242
%244:ptr<uniform, i32, read> = access %x_6, 0u, 2i, 0u
%245:i32 = load %244
%x_247:i32 = let %245
%247:f32 = convert %x_238
%248:f32 = let %247
%249:f32 = convert %x_241
%250:f32 = let %249
%251:f32 = convert %x_244
%252:f32 = let %251
%253:f32 = convert %x_247
%254:vec4<f32> = construct %248, %250, %252, %253
store %x_GLF_color, %254
%255:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%256:i32 = load %255
%x_251:i32 = let %256
store %i, %x_251
loop [b: $B27, c: $B28] { # loop_7
$B27: { # body
%x_277:ptr<function, bool, read_write> = var
%x_278_phi:ptr<function, bool, read_write> = var
%260:i32 = load %i
%x_256:i32 = let %260
%262:ptr<uniform, i32, read> = access %x_6, 0u, 1i, 0u
%263:i32 = load %262
%x_258:i32 = let %263
%265:bool = lt %x_256, %x_258
if %265 [t: $B29, f: $B30] { # if_8
$B29: { # true
exit_if # if_8
}
$B30: { # false
exit_loop # loop_7
}
}
%266:i32 = load %i
%x_261:i32 = let %266
%268:ptr<function, i32, read_write> = access %arr0, %x_261
%269:i32 = load %268
%x_263:i32 = let %269
%271:i32 = load %i
%x_264:i32 = let %271
%273:ptr<function, i32, read_write> = access %ref0, %x_264
%274:i32 = load %273
%x_266:i32 = let %274
%276:bool = neq %x_263, %x_266
%x_267:bool = let %276
store %x_278_phi, %x_267
%278:bool = eq %x_267, false
if %278 [t: $B31] { # if_9
$B31: { # true
%279:i32 = load %i
%x_271:i32 = let %279
%281:ptr<function, i32, read_write> = access %arr1, %x_271
%282:i32 = load %281
%x_273:i32 = let %282
%284:i32 = load %i
%x_274:i32 = let %284
%286:ptr<function, i32, read_write> = access %ref1, %x_274
%287:i32 = load %286
%x_276:i32 = let %287
%289:bool = neq %x_273, %x_276
store %x_277, %289
%290:bool = load %x_277
store %x_278_phi, %290
exit_if # if_9
}
}
%291:bool = load %x_278_phi
%x_278:bool = let %291
if %x_278 [t: $B32] { # if_10
$B32: { # true
%293:ptr<uniform, i32, read> = access %x_6, 0u, 3i, 0u
%294:i32 = load %293
%x_282:i32 = let %294
%296:f32 = convert %x_282
%x_283:f32 = let %296
%298:vec4<f32> = construct %x_283, %x_283, %x_283, %x_283
store %x_GLF_color, %298
exit_if # if_10
}
}
continue # -> $B28
}
$B28: { # continuing
%299:i32 = load %i
%x_285:i32 = let %299
%301:i32 = add %x_285, 1i
store %i, %301
next_iteration # -> $B27
}
}
ret
}
}
%tint_symbol = @fragment func():main_out {
$B33: {
%303:void = call %main_1
%304:vec4<f32> = load %x_GLF_color
%305:main_out = construct %304
ret %305
}
}
unhandled variable address space
********************************************************************
* The tint shader compiler has encountered an unexpected error. *
* *
* Please help us fix this issue by submitting a bug report at *
* crbug.com/tint with the source program that triggered the bug. *
********************************************************************