blob: dfd4ec1384a9ae2024d6f2acab35aedb7b76c542 [file] [log] [blame]
SKIP: FAILED
<dawn>/src/tint/lang/msl/writer/printer/printer.cc:355 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 = block { # 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
}
%func_struct_S_i11_ = func(%s:ptr<function, S, read_write>):void -> %b2 {
%b2 = block {
loop [b: %b3, c: %b4] { # loop_1
%b3 = block { # body
%6:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%x_174:f32 = load_vector_element %6, 0u
%8:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%x_176:f32 = load_vector_element %8, 1u
%10:bool = gt %x_174, %x_176
if %10 [t: %b5, f: %b6] { # if_1
%b5 = block { # true
exit_if # if_1
}
%b6 = block { # false
exit_loop # loop_1
}
}
ret
}
%b4 = block { # continuing
next_iteration %b3
}
}
%11:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%x_180:i32 = load %11
%13:ptr<function, i32, read_write> = access %s, 0u
store %13, %x_180
ret
}
}
%main_1 = func():void -> %b7 {
%b7 = block {
%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_136:ptr<function, bool, read_write> = var
%x_146:ptr<function, bool, read_write> = var
%x_137_phi:ptr<function, bool, read_write> = var
%x_147_phi:ptr<function, bool, read_write> = var
%24:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_46:i32 = load %24
store %i, %x_46
loop [b: %b8, c: %b9] { # loop_2
%b8 = block { # body
%x_51:i32 = load %i
%27:ptr<uniform, i32, read> = access %x_10, 0u, 1i, 0u
%x_53:i32 = load %27
%29:bool = lt %x_51, %x_53
if %29 [t: %b10, f: %b11] { # if_2
%b10 = block { # true
exit_if # if_2
}
%b11 = block { # false
exit_loop # loop_2
}
}
%x_56:i32 = load %i
%x_57:i32 = load %i
%32:ptr<function, i32, read_write> = access %arr, %x_56, 0u
store %32, %x_57
continue %b9
}
%b9 = block { # continuing
%x_59:i32 = load %i
%34:i32 = add %x_59, 1i
store %i, %34
next_iteration %b8
}
}
%35:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_62:i32 = load %35
store %i_1, %x_62
loop [b: %b12, c: %b13] { # loop_3
%b12 = block { # body
%x_67:i32 = load %i_1
%38:ptr<uniform, i32, read> = access %x_10, 0u, 1i, 0u
%x_69:i32 = load %38
%40:bool = lt %x_67, %x_69
if %40 [t: %b14, f: %b15] { # if_3
%b14 = block { # true
exit_if # if_3
}
%b15 = block { # false
exit_loop # loop_3
}
}
%41:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%x_73:f32 = load_vector_element %41, 0u
%43:ptr<uniform, vec2<f32>, read> = access %x_8, 0u
%x_75:f32 = load_vector_element %43, 1u
%45:bool = gt %x_73, %x_75
if %45 [t: %b16] { # if_4
%b16 = block { # true
exit_loop # loop_3
}
}
%x_79:i32 = load %i_1
%47:ptr<function, i32, read_write> = access %arr, %x_79, 0u
%x_81:i32 = load %47
%49:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%x_83:i32 = load %49
%51:bool = eq %x_81, %x_83
if %51 [t: %b17, f: %b18] { # if_5
%b17 = block { # true
%x_88:i32 = load %i_1
%53:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%x_91:i32 = load %53
%55:i32 = clamp %x_88, 0i, 3i
%56:ptr<function, i32, read_write> = access %arr, %55, 0u
store %56, %x_91
%57:ptr<function, S, read_write> = access %arr, 2i
%x_94:S = load %57
store %param, %x_94
%59:void = call %func_struct_S_i11_, %param
%x_96:S = load %param
%61:ptr<function, S, read_write> = access %arr, 2i
store %61, %x_96
exit_if # if_5
}
%b18 = block { # false
%62:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_99:i32 = load %62
store %j, %x_99
loop [b: %b19, c: %b20] { # loop_4
%b19 = block { # body
%x_104:i32 = load %j
%65:ptr<uniform, i32, read> = access %x_10, 0u, 1i, 0u
%x_106:i32 = load %65
%67:bool = lt %x_104, %x_106
if %67 [t: %b21, f: %b22] { # if_6
%b21 = block { # true
exit_if # if_6
}
%b22 = block { # false
exit_loop # loop_4
}
}
%x_109:i32 = load %j
%69:ptr<function, i32, read_write> = access %arr, %x_109, 0u
%x_111:i32 = load %69
%71:ptr<uniform, i32, read> = access %x_10, 0u, 4i, 0u
%x_113:i32 = load %71
%73:bool = gt %x_111, %x_113
if %73 [t: %b23] { # if_7
%b23 = block { # true
discard
exit_if # if_7
}
}
continue %b20
}
%b20 = block { # continuing
%x_117:i32 = load %j
%75:i32 = add %x_117, 1i
store %j, %75
next_iteration %b19
}
}
exit_if # if_5
}
}
continue %b13
}
%b13 = block { # continuing
%x_119:i32 = load %i_1
%77:i32 = add %x_119, 1i
store %i_1, %77
next_iteration %b12
}
}
%78:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_122:i32 = load %78
%80:ptr<function, i32, read_write> = access %arr, %x_122, 0u
%x_124:i32 = load %80
%82:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_126:i32 = load %82
%x_127:bool = eq %x_124, %x_126
store %x_137_phi, %x_127
if %x_127 [t: %b24] { # if_8
%b24 = block { # true
%85:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%x_131:i32 = load %85
%87:ptr<function, i32, read_write> = access %arr, %x_131, 0u
%x_133:i32 = load %87
%89:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%x_135:i32 = load %89
%91:bool = eq %x_133, %x_135
store %x_136, %91
%92:bool = load %x_136
store %x_137_phi, %92
exit_if # if_8
}
}
%x_137:bool = load %x_137_phi
store %x_147_phi, %x_137
if %x_137 [t: %b25] { # if_9
%b25 = block { # true
%94:ptr<uniform, i32, read> = access %x_10, 0u, 3i, 0u
%x_141:i32 = load %94
%96:ptr<function, i32, read_write> = access %arr, %x_141, 0u
%x_143:i32 = load %96
%98:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%x_145:i32 = load %98
%100:bool = eq %x_143, %x_145
store %x_146, %100
%101:bool = load %x_146
store %x_147_phi, %101
exit_if # if_9
}
}
%x_147:bool = load %x_147_phi
if %x_147 [t: %b26, f: %b27] { # if_10
%b26 = block { # true
%103:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%x_152:i32 = load %103
%105:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_155:i32 = load %105
%107:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_158:i32 = load %107
%109:ptr<uniform, i32, read> = access %x_10, 0u, 0i, 0u
%x_161:i32 = load %109
%111:f32 = convert %x_152
%112:f32 = convert %x_155
%113:f32 = convert %x_158
%114:f32 = convert %x_161
%115:vec4<f32> = construct %111, %112, %113, %114
store %x_GLF_color, %115
exit_if # if_10
}
%b27 = block { # false
%116:ptr<uniform, i32, read> = access %x_10, 0u, 2i, 0u
%x_165:i32 = load %116
%x_166:f32 = convert %x_165
%119:vec4<f32> = construct %x_166, %x_166, %x_166, %x_166
store %x_GLF_color, %119
exit_if # if_10
}
}
ret
}
}
%tint_symbol = @fragment func():main_out -> %b28 {
%b28 = block {
%121:void = call %main_1
%122:vec4<f32> = load %x_GLF_color
%123:main_out = construct %122
ret %123
}
}
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. *
********************************************************************