blob: 476e24a557d5c4372c0fc9cd7e535de0bdb0373b [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)
}
$B1: { # root
%x_9:ptr<uniform, buf0, read> = var @binding_point(0, 0)
%gl_FragCoord:ptr<private, vec4<f32>, read_write> = var
%x_GLF_color:ptr<private, vec4<f32>, read_write> = var
}
%main_1 = func():void {
$B2: {
%x_43:ptr<function, f32, read_write> = var
%x_44:ptr<function, f32, read_write> = var
%x_45:ptr<function, f32, read_write> = var
%x_46:ptr<function, i32, read_write> = var
%zero:ptr<function, i32, read_write> = var
%param:ptr<function, vec2<f32>, read_write> = var
%temp:ptr<function, vec2<f32>, read_write> = var
%12:vec4<f32> = load %gl_FragCoord
%13:vec2<f32> = swizzle %12, xy
store %param, %13
loop [b: $B3] { # loop_1
$B3: { # body
%14:f32 = load_vector_element %param, 1u
%15:bool = lt %14, 50.0f
if %15 [t: $B4, f: $B5] { # if_1
$B4: { # true
%16:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%17:f32 = load_vector_element %16, 1u
store %x_44, %17
exit_if # if_1
}
$B5: { # false
store %x_44, 0.0f
exit_if # if_1
}
}
%18:f32 = load %x_44
%x_61:f32 = let %18
%20:f32 = load %x_44
store %x_43, %20
%21:f32 = load_vector_element %gl_FragCoord, 1u
%22:bool = lt %21, 50.0f
%23:f32 = select 0.0f, 1.0f, %22
%x_65:f32 = let %23
store %x_45, %x_65
%25:f32 = sub %x_61, %x_65
%26:bool = lt %25, 1.0f
if %26 [t: $B6] { # if_2
$B6: { # true
store %x_46, 0i
exit_loop # loop_1
}
}
store %x_46, 1i
exit_loop # loop_1
}
}
%27:i32 = load %x_46
%x_70:i32 = let %27
%29:i32 = load %x_46
store %zero, %29
%30:bool = eq %x_70, 1i
if %30 [t: $B7] { # if_3
$B7: { # true
ret
}
}
store %x_GLF_color, vec4<f32>(0.0f, 1.0f, 1.0f, 1.0f)
%31:f32 = load_vector_element %gl_FragCoord, 0u
%32:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%33:f32 = load_vector_element %32, 0u
%34:bool = gte %31, %33
if %34 [t: $B8] { # if_4
$B8: { # true
%35:f32 = load_vector_element %gl_FragCoord, 1u
%36:bool = gte %35, 0.0f
if %36 [t: $B9] { # if_5
$B9: { # true
%37:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%38:f32 = load_vector_element %37, 1u
store_vector_element %x_GLF_color, 0u, %38
exit_if # if_5
}
}
exit_if # if_4
}
}
%39:f32 = load_vector_element %gl_FragCoord, 1u
%40:bool = gte %39, 0.0f
if %40 [t: $B10] { # if_6
$B10: { # true
%41:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%42:f32 = load_vector_element %41, 0u
store_vector_element %x_GLF_color, 1u, %42
exit_if # if_6
}
}
%43:vec4<f32> = load %gl_FragCoord
%44:vec2<f32> = swizzle %43, xy
%x_98:vec2<f32> = let %44
%46:f32 = access %x_98, 0u
%47:f32 = access %x_98, 1u
%48:vec2<f32> = construct %46, %47
%x_101:vec2<f32> = let %48
store %temp, %x_101
%50:f32 = access %x_101, 1u
%51:bool = gte %50, 0.0f
if %51 [t: $B11] { # if_7
$B11: { # true
%52:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%53:f32 = load_vector_element %52, 0u
store_vector_element %x_GLF_color, 2u, %53
exit_if # if_7
}
}
ret
}
}
%tint_symbol = @fragment func(%gl_FragCoord_param:vec4<f32> [@position]):main_out {
$B12: {
store %gl_FragCoord, %gl_FragCoord_param
%56:void = call %main_1
%57:vec4<f32> = load %x_GLF_color
%58:main_out = construct %57
ret %58
}
}
%alwaysZero_vf2_ = func(%coord:ptr<function, vec2<f32>, read_write>):i32 {
$B13: {
%a:ptr<function, f32, read_write> = var
%x_110:ptr<function, f32, read_write> = var
%b:ptr<function, f32, read_write> = var
%64:f32 = load_vector_element %coord, 1u
%65:bool = lt %64, 50.0f
if %65 [t: $B14, f: $B15] { # if_8
$B14: { # true
%66:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%67:f32 = load_vector_element %66, 1u
store %x_110, %67
exit_if # if_8
}
$B15: { # false
store %x_110, 0.0f
exit_if # if_8
}
}
%68:f32 = load %x_110
%x_119:f32 = let %68
%70:f32 = load %x_110
store %a, %70
%71:f32 = load_vector_element %gl_FragCoord, 1u
%72:bool = lt %71, 50.0f
%73:f32 = select 0.0f, 1.0f, %72
%x_123:f32 = let %73
store %b, %x_123
%75:f32 = sub %x_119, %x_123
%76:bool = lt %75, 1.0f
if %76 [t: $B16] { # if_9
$B16: { # true
ret 0i
}
}
ret 1i
}
}
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. *
********************************************************************