blob: 71767f8eab58d3e7c62ea26c5aa930c494f3ac6e [file] [log] [blame]
SKIP: FAILED
../../src/tint/lang/msl/writer/printer/printer.cc:500 internal compiler error: buf1 = struct @align(8) {
resolution:vec2<f32> @offset(0)
}
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
%gl_FragCoord:ptr<private, vec4<f32>, read_write> = var
%x_6:ptr<uniform, buf1, read> = var @binding_point(0, 1)
%x_9:ptr<uniform, buf0, read> = var @binding_point(0, 0)
%x_GLF_color:ptr<private, vec4<f32>, read_write> = var
}
%main_1 = func():void {
$B2: {
%data:ptr<function, array<f32, 10>, read_write> = var
%x_40_phi:ptr<function, i32, read_write> = var
%x_52_phi:ptr<function, i32, read_write> = var
store %x_40_phi, 0i
loop [b: $B3, c: $B4] { # loop_1
$B3: { # body
%x_41:ptr<function, i32, read_write> = var
%10:i32 = load %x_40_phi
%x_40:i32 = let %10
%12:bool = lt %x_40, 10i
if %12 [t: $B5, f: $B6] { # if_1
$B5: { # true
exit_if # if_1
}
$B6: { # false
exit_loop # loop_1
}
}
continue # -> $B4
}
$B4: { # continuing
%13:ptr<uniform, vec2<f32>, read> = access %x_9, 0u
%14:f32 = load_vector_element %13, 1u
%x_48:f32 = let %14
%16:ptr<function, f32, read_write> = access %data, %x_40
%17:i32 = sub 10i, %x_40
%18:f32 = convert %17
%19:f32 = mul %18, %x_48
store %16, %19
%20:i32 = add %x_40, 1i
store %x_41, %20
%21:i32 = load %x_41
store %x_40_phi, %21
next_iteration # -> $B3
}
}
store %x_52_phi, 0i
loop [b: $B7, c: $B8] { # loop_2
$B7: { # body
%x_53:ptr<function, i32, read_write> = var
%x_59_phi:ptr<function, i32, read_write> = var
%24:i32 = load %x_52_phi
%x_52:i32 = let %24
%26:bool = lt %x_52, 9i
if %26 [t: $B9, f: $B10] { # if_2
$B9: { # true
exit_if # if_2
}
$B10: { # false
exit_loop # loop_2
}
}
store %x_59_phi, 0i
loop [b: $B11, c: $B12] { # loop_3
$B11: { # body
%x_82:ptr<function, bool, read_write> = var
%x_83:ptr<function, bool, read_write> = var
%x_60:ptr<function, i32, read_write> = var
%x_84_phi:ptr<function, bool, read_write> = var
%31:i32 = load %x_59_phi
%x_59:i32 = let %31
%33:bool = lt %x_59, 10i
if %33 [t: $B13, f: $B14] { # if_3
$B13: { # true
exit_if # if_3
}
$B14: { # false
exit_loop # loop_3
}
}
%34:i32 = add %x_52, 1i
%35:bool = lt %x_59, %34
if %35 [t: $B15] { # if_4
$B15: { # true
continue # -> $B12
}
}
%x_69_save:i32 = let %x_52
%37:ptr<function, f32, read_write> = access %data, %x_69_save
%38:f32 = load %37
%x_70:f32 = let %38
%x_71_save:i32 = let %x_59
%41:ptr<function, f32, read_write> = access %data, %x_71_save
%42:f32 = load %41
%x_72:f32 = let %42
%44:f32 = load_vector_element %gl_FragCoord, 1u
%x_74:f32 = let %44
%46:ptr<uniform, vec2<f32>, read> = access %x_6, 0u
%47:f32 = load_vector_element %46, 1u
%x_76:f32 = let %47
%49:f32 = mul %x_76, 0.5f
%50:bool = lt %x_74, %49
if %50 [t: $B16, f: $B17] { # if_5
$B16: { # true
%51:bool = gt %x_70, %x_72
store %x_82, %51
%52:bool = load %x_82
store %x_84_phi, %52
exit_if # if_5
}
$B17: { # false
%53:bool = lt %x_70, %x_72
store %x_83, %53
%54:bool = load %x_83
store %x_84_phi, %54
exit_if # if_5
}
}
%55:bool = load %x_84_phi
%x_84:bool = let %55
if %x_84 [t: $B18] { # if_6
$B18: { # true
%57:ptr<function, f32, read_write> = access %data, %x_69_save
%58:f32 = load %57
%x_87:f32 = let %58
%60:ptr<function, f32, read_write> = access %data, %x_71_save
%61:f32 = load %60
%x_88:f32 = let %61
%63:ptr<function, f32, read_write> = access %data, %x_69_save
store %63, %x_88
%64:ptr<function, f32, read_write> = access %data, %x_71_save
store %64, %x_87
exit_if # if_6
}
}
continue # -> $B12
}
$B12: { # continuing
%65:i32 = add %x_59, 1i
store %x_60, %65
%66:i32 = load %x_60
store %x_59_phi, %66
next_iteration # -> $B11
}
}
continue # -> $B8
}
$B8: { # continuing
%67:i32 = add %x_52, 1i
store %x_53, %67
%68:i32 = load %x_53
store %x_52_phi, %68
next_iteration # -> $B7
}
}
%69:f32 = load_vector_element %gl_FragCoord, 0u
%x_90:f32 = let %69
%71:ptr<uniform, vec2<f32>, read> = access %x_6, 0u
%72:f32 = load_vector_element %71, 0u
%x_92:f32 = let %72
%74:f32 = mul %x_92, 0.5f
%75:bool = lt %x_90, %74
if %75 [t: $B19, f: $B20] { # if_7
$B19: { # true
%76:ptr<function, f32, read_write> = access %data, 0i
%77:f32 = load %76
%x_99:f32 = let %77
%79:ptr<function, f32, read_write> = access %data, 5i
%80:f32 = load %79
%x_102:f32 = let %80
%82:ptr<function, f32, read_write> = access %data, 9i
%83:f32 = load %82
%x_105:f32 = let %83
%85:f32 = mul %x_99, 0.10000000149011611938f
%86:f32 = mul %x_102, 0.10000000149011611938f
%87:f32 = mul %x_105, 0.10000000149011611938f
%88:vec4<f32> = construct %85, %86, %87, 1.0f
store %x_GLF_color, %88
exit_if # if_7
}
$B20: { # false
%89:ptr<function, f32, read_write> = access %data, 5i
%90:f32 = load %89
%x_109:f32 = let %90
%92:ptr<function, f32, read_write> = access %data, 9i
%93:f32 = load %92
%x_112:f32 = let %93
%95:ptr<function, f32, read_write> = access %data, 0i
%96:f32 = load %95
%x_115:f32 = let %96
%98:f32 = mul %x_109, 0.10000000149011611938f
%99:f32 = mul %x_112, 0.10000000149011611938f
%100:f32 = mul %x_115, 0.10000000149011611938f
%101:vec4<f32> = construct %98, %99, %100, 1.0f
store %x_GLF_color, %101
exit_if # if_7
}
}
ret
}
}
%tint_symbol = @fragment func(%gl_FragCoord_param:vec4<f32> [@position]):main_out {
$B21: {
store %gl_FragCoord, %gl_FragCoord_param
%104:void = call %main_1
%105:vec4<f32> = load %x_GLF_color
%106:main_out = construct %105
ret %106
}
}
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. *
********************************************************************