blob: 1fd3847e047dcd41ba546246f731cedfbe215729 [file] [log] [blame]
SKIP: FAILED
../../src/tint/lang/msl/writer/printer/printer.cc:500 internal compiler error: buf1 = struct @align(8) {
v1:vec2<f32> @offset(0)
}
strided_arr = struct @align(4) {
el:i32 @offset(0)
}
buf0 = struct @align(4) {
x_GLF_uniform_int_values:array<strided_arr, 5> @offset(0)
}
S = struct @align(4) {
data:i32 @offset(0)
}
main_out = struct @align(16) {
x_GLF_color_1:vec4<f32> @offset(0), @location(0)
}
$B1: { # root
%x_8:ptr<uniform, buf1, read> = var @binding_point(0, 1)
%x_10:ptr<uniform, buf0, read> = var @binding_point(0, 0)
%x_GLF_color:ptr<private, vec4<f32>, read_write> = var
%continue_execution:ptr<private, bool, read_write> = var, true
}
%func_struct_S_i11_ = func(%s:ptr<function, S, read_write>):void {
$B2: {
%7:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%8:f32 = load_vector_element %7, 0u
%x_166:f32 = let %8
%10:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%11:f32 = load_vector_element %10, 1u
%x_168:f32 = let %11
%13:bool = gt %x_166, %x_168
if %13 [t: $B3] { # if_1
$B3: { # true
ret
}
}
%14:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%15:i32 = load %14
%x_173:i32 = let %15
%17:ptr<function, i32, read_write> = access %s, 0u
store %17, %x_173
ret
}
}
%main_1 = func():void {
$B4: {
%i:ptr<function, i32, read_write> = var
%arr:ptr<function, array<S, 3>, read_write> = var
%i_1:ptr<function, i32, read_write> = var
%param:ptr<function, S, read_write> = var
%j:ptr<function, i32, read_write> = var
%x_132:ptr<function, bool, read_write> = var
%x_142:ptr<function, bool, read_write> = var
%x_133_phi:ptr<function, bool, read_write> = var
%x_143_phi:ptr<function, bool, read_write> = var
%28:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%29:i32 = load %28
%x_46:i32 = let %29
store %i, %x_46
loop [b: $B5, c: $B6] { # loop_1
$B5: { # body
%31:i32 = load %i
%x_51:i32 = let %31
%33:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%34:i32 = load %33
%x_53:i32 = let %34
%36:bool = lt %x_51, %x_53
if %36 [t: $B7, f: $B8] { # if_2
$B7: { # true
exit_if # if_2
}
$B8: { # false
exit_loop # loop_1
}
}
%37:i32 = load %i
%x_56:i32 = let %37
%39:i32 = load %i
%x_57:i32 = let %39
%41:ptr<function, i32, read_write> = access %arr, %x_56, 0u
store %41, %x_57
continue # -> $B6
}
$B6: { # continuing
%42:i32 = load %i
%x_59:i32 = let %42
%44:i32 = add %x_59, 1i
store %i, %44
next_iteration # -> $B5
}
}
%45:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%46:i32 = load %45
%x_62:i32 = let %46
store %i_1, %x_62
loop [b: $B9, c: $B10] { # loop_2
$B9: { # body
%48:i32 = load %i_1
%x_67:i32 = let %48
%50:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%51:i32 = load %50
%x_69:i32 = let %51
%53:bool = lt %x_67, %x_69
if %53 [t: $B11, f: $B12] { # if_3
$B11: { # true
exit_if # if_3
}
$B12: { # false
exit_loop # loop_2
}
}
%54:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%55:f32 = load_vector_element %54, 0u
%x_73:f32 = let %55
%57:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%58:f32 = load_vector_element %57, 1u
%x_75:f32 = let %58
%60:bool = gt %x_73, %x_75
if %60 [t: $B13] { # if_4
$B13: { # true
exit_loop # loop_2
}
}
%61:i32 = load %i_1
%x_79:i32 = let %61
%63:ptr<function, i32, read_write> = access %arr, %x_79, 0u
%64:i32 = load %63
%x_81:i32 = let %64
%66:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%67:i32 = load %66
%x_83:i32 = let %67
%69:bool = eq %x_81, %x_83
if %69 [t: $B14, f: $B15] { # if_5
$B14: { # true
%70:i32 = load %i_1
%x_88:i32 = let %70
%72:ptr<function, S, read_write> = access %arr, %x_88
%73:S = load %72
%x_90:S = let %73
store %param, %x_90
%75:void = call %func_struct_S_i11_, %param
%76:S = load %param
%x_92:S = let %76
%78:ptr<function, S, read_write> = access %arr, %x_88
store %78, %x_92
exit_if # if_5
}
$B15: { # false
%79:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%80:i32 = load %79
%x_95:i32 = let %80
store %j, %x_95
loop [b: $B16, c: $B17] { # loop_3
$B16: { # body
%82:i32 = load %j
%x_100:i32 = let %82
%84:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%85:i32 = load %84
%x_102:i32 = let %85
%87:bool = lt %x_100, %x_102
if %87 [t: $B18, f: $B19] { # if_6
$B18: { # true
exit_if # if_6
}
$B19: { # false
exit_loop # loop_3
}
}
%88:i32 = load %j
%x_105:i32 = let %88
%90:ptr<function, i32, read_write> = access %arr, %x_105, 0u
%91:i32 = load %90
%x_107:i32 = let %91
%93:ptr<uniform, i32, read> = access %x_10, 0u, 4i, 0u
%94:i32 = load %93
%x_109:i32 = let %94
%96:bool = gt %x_107, %x_109
if %96 [t: $B20] { # if_7
$B20: { # true
store %continue_execution, false
exit_if # if_7
}
}
continue # -> $B17
}
$B17: { # continuing
%97:i32 = load %j
%x_113:i32 = let %97
%99:i32 = add %x_113, 1i
store %j, %99
next_iteration # -> $B16
}
}
exit_if # if_5
}
}
continue # -> $B10
}
$B10: { # continuing
%100:i32 = load %i_1
%x_115:i32 = let %100
%102:i32 = add %x_115, 1i
store %i_1, %102
next_iteration # -> $B9
}
}
%103:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%104:i32 = load %103
%x_118:i32 = let %104
%106:ptr<function, i32, read_write> = access %arr, %x_118, 0u
%107:i32 = load %106
%x_120:i32 = let %107
%109:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%110:i32 = load %109
%x_122:i32 = let %110
%112:bool = eq %x_120, %x_122
%x_123:bool = let %112
store %x_133_phi, %x_123
if %x_123 [t: $B21] { # if_8
$B21: { # true
%114:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%115:i32 = load %114
%x_127:i32 = let %115
%117:ptr<function, i32, read_write> = access %arr, %x_127, 0u
%118:i32 = load %117
%x_129:i32 = let %118
%120:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%121:i32 = load %120
%x_131:i32 = let %121
%123:bool = eq %x_129, %x_131
store %x_132, %123
%124:bool = load %x_132
store %x_133_phi, %124
exit_if # if_8
}
}
%125:bool = load %x_133_phi
%x_133:bool = let %125
store %x_143_phi, %x_133
if %x_133 [t: $B22] { # if_9
$B22: { # true
%127:ptr<uniform, i32, read> = access %x_10, 0u, 1i, 0u
%128:i32 = load %127
%x_137:i32 = let %128
%130:ptr<function, i32, read_write> = access %arr, %x_137, 0u
%131:i32 = load %130
%x_139:i32 = let %131
%133:ptr<uniform, i32, read> = access %x_10, 0u, 1i, 0u
%134:i32 = load %133
%x_141:i32 = let %134
%136:bool = eq %x_139, %x_141
store %x_142, %136
%137:bool = load %x_142
store %x_143_phi, %137
exit_if # if_9
}
}
%138:bool = load %x_143_phi
%x_143:bool = let %138
if %x_143 [t: $B23, f: $B24] { # if_10
$B23: { # true
%140:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%141:i32 = load %140
%x_148:i32 = let %141
%143:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%144:i32 = load %143
%x_151:i32 = let %144
%146:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%147:i32 = load %146
%x_154:i32 = let %147
%149:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%150:i32 = load %149
%x_157:i32 = let %150
%152:f32 = convert %x_148
%153:f32 = let %152
%154:f32 = convert %x_151
%155:f32 = let %154
%156:f32 = convert %x_154
%157:f32 = let %156
%158:f32 = convert %x_157
%159:vec4<f32> = construct %153, %155, %157, %158
store %x_GLF_color, %159
exit_if # if_10
}
$B24: { # false
%160:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%161:i32 = load %160
%x_161:i32 = let %161
%163:f32 = convert %x_161
%x_162:f32 = let %163
%165:vec4<f32> = construct %x_162, %x_162, %x_162, %x_162
store %x_GLF_color, %165
exit_if # if_10
}
}
ret
}
}
%tint_symbol = @fragment func():main_out {
$B25: {
%167:void = call %main_1
%168:vec4<f32> = load %x_GLF_color
%169:main_out = construct %168
%170:bool = load %continue_execution
%171:bool = eq %170, false
if %171 [t: $B26] { # if_11
$B26: { # true
terminate_invocation
}
}
ret %169
}
}
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. *
********************************************************************