| 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_7:ptr<uniform, buf0, read> = var @binding_point(0, 0) |
| %x_GLF_color:ptr<private, vec4<f32>, read_write> = var |
| } |
| |
| %main_1 = func():void { |
| $B2: { |
| %a:ptr<function, i32, read_write> = var |
| %i:ptr<function, i32, read_write> = var |
| store %a, 0i |
| store %i, 0i |
| loop [b: $B3, c: $B4] { # loop_1 |
| $B3: { # body |
| %6:i32 = load %i |
| %7:i32 = let %6 |
| %8:ptr<uniform, vec2<f32>, read> = access %x_7, 0u |
| %9:f32 = load_vector_element %8, 1u |
| %10:i32 = call %tint_f32_to_i32, %9 |
| %12:bool = lt %7, %10 |
| if %12 [t: $B5, f: $B6] { # if_1 |
| $B5: { # true |
| exit_if # if_1 |
| } |
| $B6: { # false |
| exit_loop # loop_1 |
| } |
| } |
| %13:i32 = load %a |
| %14:bool = gt %13, 0i |
| if %14 [t: $B7] { # if_2 |
| $B7: { # true |
| exit_loop # loop_1 |
| } |
| } |
| %15:ptr<uniform, vec2<f32>, read> = access %x_7, 0u |
| %16:f32 = load_vector_element %15, 1u |
| %17:i32 = call %tint_f32_to_i32, %16 |
| %18:i32 = mul %17, 2i |
| %19:i32 = call %tint_div_i32, %18, 2i |
| store %a, %19 |
| continue # -> $B4 |
| } |
| $B4: { # continuing |
| %21:i32 = load %i |
| %22:i32 = add %21, 1i |
| store %i, %22 |
| next_iteration # -> $B3 |
| } |
| } |
| %23:i32 = load %a |
| %24:bool = eq %23, 1i |
| if %24 [t: $B8, f: $B9] { # if_3 |
| $B8: { # true |
| store %x_GLF_color, vec4<f32>(1.0f, 0.0f, 0.0f, 1.0f) |
| exit_if # if_3 |
| } |
| $B9: { # false |
| store %x_GLF_color, vec4<f32>(0.0f) |
| exit_if # if_3 |
| } |
| } |
| ret |
| } |
| } |
| %tint_symbol = @fragment func():main_out { |
| $B10: { |
| %26:void = call %main_1 |
| %27:vec4<f32> = load %x_GLF_color |
| %28:main_out = construct %27 |
| ret %28 |
| } |
| } |
| %tint_div_i32 = func(%lhs:i32, %rhs:i32):i32 { |
| $B11: { |
| %31:bool = eq %rhs, 0i |
| %32:bool = eq %lhs, -2147483648i |
| %33:bool = eq %rhs, -1i |
| %34:bool = and %32, %33 |
| %35:bool = or %31, %34 |
| %36:i32 = select %rhs, 1i, %35 |
| %37:i32 = div %lhs, %36 |
| ret %37 |
| } |
| } |
| %tint_f32_to_i32 = func(%value:f32):i32 { |
| $B12: { |
| %39:i32 = convert %value |
| %40:bool = gte %value, -2147483648.0f |
| %41:i32 = select -2147483648i, %39, %40 |
| %42:bool = lte %value, 2147483520.0f |
| %43:i32 = select 2147483647i, %41, %42 |
| ret %43 |
| } |
| } |
| |
| 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. * |
| ******************************************************************** |