blob: 0a7eaed1af488128510f9d48b54dde72978c009f [file] [log] [blame]
SKIP: FAILED
../../src/tint/lang/msl/writer/printer/printer.cc:500 internal compiler error: buf0 = struct @align(8) {
injectionSwitch:vec2<f32> @offset(0)
}
main_out = struct @align(16) {
x_GLF_color_1:vec4<f32> @offset(0), @location(0)
}
tmp_struct = struct @align(4) {
nmb:array<i32, 1> @offset(0)
}
$B1: { # root
%x_11: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
}
%main_1 = func():void {
$B2: {
%x_24:ptr<function, array<i32, 1>, read_write> = var
%x_68:ptr<function, bool, read_write> = var, false
%x_17:ptr<function, i32, read_write> = var
%x_18:ptr<function, i32, read_write> = var
%x_19:ptr<function, i32, read_write> = var
%x_20:ptr<function, i32, read_write> = var
%x_69:ptr<function, bool, read_write> = var, false
%tmp_float:ptr<function, f32, read_write> = var
%color:ptr<function, vec3<f32>, read_write> = var
loop [b: $B3] { # loop_1
$B3: { # body
%x_79:ptr<function, bool, read_write> = var
%x_25:ptr<function, i32, read_write> = var
%x_26:ptr<function, i32, read_write> = var
%x_101:ptr<function, vec3<f32>, read_write> = var
%18:ptr<uniform, vec2<f32>, read> = access %x_11, 0u
%19:f32 = load_vector_element %18, 1u
%x_75:f32 = let %19
store %tmp_float, %x_75
%21:vec3<f32> = construct %x_75
%x_76:vec3<f32> = let %21
store %color, %x_76
store %x_24, array<i32, 1>(0i)
store %x_68, false
store %x_79, false
loop [b: $B4] { # loop_2
$B4: { # body
%x_21:ptr<function, i32, read_write> = var
%x_93:ptr<function, bool, read_write> = var
store %x_18, 1i
store %x_21, 1i
loop [b: $B5, c: $B6] { # loop_3
$B5: { # body
store %x_25, 0i
%25:bool = load %x_79
store %x_93, %25
%26:i32 = load %x_21
%27:bool = gt %26, 10i
if %27 [t: $B7, f: $B8] { # if_1
$B7: { # true
exit_if # if_1
}
$B8: { # false
exit_loop # loop_3
}
}
%28:i32 = load %x_21
%29:i32 = sub %28, 1i
%x_22:i32 = let %29
store %x_19, %x_22
%31:ptr<function, i32, read_write> = access %x_24, %x_22
%32:i32 = load %31
%33:bool = eq %32, 1i
if %33 [t: $B9] { # if_2
$B9: { # true
store %x_68, true
store %x_17, 1i
store %x_25, 1i
store %x_93, true
exit_loop # loop_3
}
}
store %x_18, %x_22
continue # -> $B6
}
$B6: { # continuing
store %x_21, %x_22
next_iteration # -> $B5
}
}
%34:i32 = load %x_25
store %x_26, %34
%35:bool = load %x_93
if %35 [t: $B10] { # if_3
$B10: { # true
exit_loop # loop_2
}
}
store %x_68, true
store %x_17, -1i
store %x_26, -1i
exit_loop # loop_2
}
}
%36:i32 = load %x_26
store %x_20, %36
%37:i32 = load %x_26
%38:bool = eq %37, -1i
if %38 [t: $B11, f: $B12] { # if_4
$B11: { # true
store %continue_execution, false
exit_if # if_4
}
$B12: { # false
store %x_GLF_color, vec4<f32>(0.0f)
%39:f32 = access %x_76, 0u
%40:vec2<f32> = swizzle %x_76, yz
%41:vec2<f32> = add %40, vec2<f32>(1.0f)
%42:vec2<f32> = swizzle %41, xy
%43:vec3<f32> = construct %39, %42
store %x_101, %43
%44:vec3<f32> = load %x_101
store %color, %44
%45:ptr<uniform, vec2<f32>, read> = access %x_11, 0u
%46:f32 = load_vector_element %45, 0u
%47:bool = gt %46, 1.0f
if %47 [t: $B13] { # if_5
$B13: { # true
store %x_69, true
exit_loop # loop_1
}
}
exit_if # if_4
}
}
%48:f32 = load_vector_element %x_101, 0u
%49:f32 = load_vector_element %x_101, 1u
%50:f32 = load_vector_element %x_101, 2u
%51:vec4<f32> = construct %48, %49, %50, 1.0f
store %x_GLF_color, %51
store %x_69, true
exit_loop # loop_1
}
}
ret
}
}
%tint_symbol = @fragment func():main_out {
$B14: {
%53:void = call %main_1
%54:vec4<f32> = load %x_GLF_color
%55:main_out = construct %54
%56:bool = load %continue_execution
%57:bool = eq %56, false
if %57 [t: $B15] { # if_6
$B15: { # true
terminate_invocation
}
}
ret %55
}
}
%binarySearch_struct_tmp_struct_i1_1_1_ = func(%obj:ptr<function, tmp_struct, read_write>):i32 {
$B16: {
%x_112:ptr<function, bool, read_write> = var, false
%x_16:ptr<function, i32, read_write> = var
%one:ptr<function, i32, read_write> = var
%zero:ptr<function, i32, read_write> = var
%x_114:ptr<function, bool, read_write> = var
%x_27:ptr<function, i32, read_write> = var
%x_28:ptr<function, i32, read_write> = var
store %x_114, false
loop [b: $B17] { # loop_4
$B17: { # body
%x_15:ptr<function, i32, read_write> = var
%x_128:ptr<function, bool, read_write> = var
store %one, 1i
store %x_15, 1i
loop [b: $B18, c: $B19] { # loop_5
$B18: { # body
store %x_27, 0i
%69:bool = load %x_114
store %x_128, %69
%70:i32 = load %x_15
%71:bool = gt %70, 10i
if %71 [t: $B20, f: $B21] { # if_7
$B20: { # true
exit_if # if_7
}
$B21: { # false
exit_loop # loop_5
}
}
%72:i32 = load %x_15
%73:i32 = sub %72, 1i
%x_13:i32 = let %73
store %zero, %x_13
%75:ptr<function, i32, read_write> = access %obj, 0u, %x_13
%76:i32 = load %75
%77:bool = eq %76, 1i
if %77 [t: $B22] { # if_8
$B22: { # true
store %x_112, true
store %x_16, 1i
store %x_27, 1i
store %x_128, true
exit_loop # loop_5
}
}
store %one, %x_13
continue # -> $B19
}
$B19: { # continuing
store %x_15, %x_13
next_iteration # -> $B18
}
}
%78:i32 = load %x_27
store %x_28, %78
%79:bool = load %x_128
if %79 [t: $B23] { # if_9
$B23: { # true
exit_loop # loop_4
}
}
store %x_112, true
store %x_16, -1i
store %x_28, -1i
exit_loop # loop_4
}
}
%80:i32 = load %x_28
ret %80
}
}
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. *
********************************************************************