| 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_9:ptr<uniform, buf1, read> = var @binding_point(0, 1) |
| %x_13:ptr<uniform, buf0, read> = var @binding_point(0, 0) |
| %x_GLF_color:ptr<private, vec4<f32>, read_write> = var |
| } |
| |
| %checkSwap_f1_f1_ = func(%a:ptr<function, f32, read_write>, %b:ptr<function, f32, read_write>):bool { |
| $B2: { |
| %x_144:ptr<function, bool, read_write> = var |
| %9:f32 = load_vector_element %gl_FragCoord, 1u |
| %10:ptr<uniform, vec2<f32>, read> = access %x_9, 0u |
| %11:f32 = load_vector_element %10, 1u |
| %12:f32 = div %11, 2.0f |
| %13:bool = lt %9, %12 |
| if %13 [t: $B3, f: $B4] { # if_1 |
| $B3: { # true |
| %14:f32 = load %a |
| %15:f32 = load %b |
| %16:bool = gt %14, %15 |
| store %x_144, %16 |
| exit_if # if_1 |
| } |
| $B4: { # false |
| %17:f32 = load %a |
| %18:f32 = load %b |
| %19:bool = lt %17, %18 |
| store %x_144, %19 |
| exit_if # if_1 |
| } |
| } |
| %20:bool = load %x_144 |
| %x_160:bool = let %20 |
| ret %x_160 |
| } |
| } |
| %main_1 = func():void { |
| $B5: { |
| %i:ptr<function, i32, read_write> = var |
| %data:ptr<function, array<f32, 10>, read_write> = var |
| %i_1:ptr<function, i32, read_write> = var |
| %j:ptr<function, i32, read_write> = var |
| %doSwap:ptr<function, bool, read_write> = var |
| %param:ptr<function, f32, read_write> = var |
| %param_1:ptr<function, f32, read_write> = var |
| %temp:ptr<function, f32, read_write> = var |
| store %i, 0i |
| loop [b: $B6, c: $B7] { # loop_1 |
| $B6: { # body |
| %31:i32 = load %i |
| %32:bool = lt %31, 10i |
| if %32 [t: $B8, f: $B9] { # if_2 |
| $B8: { # true |
| exit_if # if_2 |
| } |
| $B9: { # false |
| exit_loop # loop_1 |
| } |
| } |
| %33:i32 = load %i |
| %x_59:i32 = let %33 |
| %35:ptr<function, f32, read_write> = access %data, %x_59 |
| %36:i32 = load %i |
| %37:i32 = sub 10i, %36 |
| %38:f32 = convert %37 |
| %39:ptr<uniform, vec2<f32>, read> = access %x_13, 0u |
| %40:f32 = load_vector_element %39, 1u |
| %41:f32 = mul %38, %40 |
| store %35, %41 |
| continue # -> $B7 |
| } |
| $B7: { # continuing |
| %42:i32 = load %i |
| %43:i32 = add %42, 1i |
| store %i, %43 |
| next_iteration # -> $B6 |
| } |
| } |
| store %i_1, 0i |
| loop [b: $B10, c: $B11] { # loop_2 |
| $B10: { # body |
| %44:i32 = load %i_1 |
| %45:bool = lt %44, 9i |
| if %45 [t: $B12, f: $B13] { # if_3 |
| $B12: { # true |
| exit_if # if_3 |
| } |
| $B13: { # false |
| exit_loop # loop_2 |
| } |
| } |
| store %j, 0i |
| loop [b: $B14, c: $B15] { # loop_3 |
| $B14: { # body |
| %46:i32 = load %j |
| %47:bool = lt %46, 10i |
| if %47 [t: $B16, f: $B17] { # if_4 |
| $B16: { # true |
| exit_if # if_4 |
| } |
| $B17: { # false |
| exit_loop # loop_3 |
| } |
| } |
| %48:i32 = load %j |
| %49:i32 = load %i_1 |
| %50:i32 = add %49, 1i |
| %51:bool = lt %48, %50 |
| if %51 [t: $B18] { # if_5 |
| $B18: { # true |
| continue # -> $B15 |
| } |
| } |
| %52:i32 = load %j |
| %x_90:i32 = let %52 |
| %54:i32 = load %i_1 |
| %55:ptr<function, f32, read_write> = access %data, %54 |
| %56:f32 = load %55 |
| store %param, %56 |
| %57:ptr<function, f32, read_write> = access %data, %x_90 |
| %58:f32 = load %57 |
| store %param_1, %58 |
| %59:bool = call %checkSwap_f1_f1_, %param, %param_1 |
| %x_95:bool = let %59 |
| store %doSwap, %x_95 |
| %61:bool = load %doSwap |
| if %61 [t: $B19] { # if_6 |
| $B19: { # true |
| %62:i32 = load %i_1 |
| %63:ptr<function, f32, read_write> = access %data, %62 |
| %64:f32 = load %63 |
| store %temp, %64 |
| %65:i32 = load %i_1 |
| %x_102:i32 = let %65 |
| %67:ptr<function, f32, read_write> = access %data, %x_102 |
| %68:i32 = load %j |
| %69:ptr<function, f32, read_write> = access %data, %68 |
| %70:f32 = load %69 |
| store %67, %70 |
| %71:i32 = load %j |
| %x_107:i32 = let %71 |
| %73:ptr<function, f32, read_write> = access %data, %x_107 |
| %74:f32 = load %temp |
| store %73, %74 |
| exit_if # if_6 |
| } |
| } |
| continue # -> $B15 |
| } |
| $B15: { # continuing |
| %75:i32 = load %j |
| %76:i32 = add %75, 1i |
| store %j, %76 |
| next_iteration # -> $B14 |
| } |
| } |
| continue # -> $B11 |
| } |
| $B11: { # continuing |
| %77:i32 = load %i_1 |
| %78:i32 = add %77, 1i |
| store %i_1, %78 |
| next_iteration # -> $B10 |
| } |
| } |
| %79:f32 = load_vector_element %gl_FragCoord, 0u |
| %80:ptr<uniform, vec2<f32>, read> = access %x_9, 0u |
| %81:f32 = load_vector_element %80, 0u |
| %82:f32 = div %81, 2.0f |
| %83:bool = lt %79, %82 |
| if %83 [t: $B20, f: $B21] { # if_7 |
| $B20: { # true |
| %84:ptr<function, f32, read_write> = access %data, 0i |
| %85:f32 = load %84 |
| %86:f32 = div %85, 10.0f |
| %87:ptr<function, f32, read_write> = access %data, 5i |
| %88:f32 = load %87 |
| %89:f32 = div %88, 10.0f |
| %90:ptr<function, f32, read_write> = access %data, 9i |
| %91:f32 = load %90 |
| %92:f32 = div %91, 10.0f |
| %93:vec4<f32> = construct %86, %89, %92, 1.0f |
| store %x_GLF_color, %93 |
| exit_if # if_7 |
| } |
| $B21: { # false |
| %94:ptr<function, f32, read_write> = access %data, 5i |
| %95:f32 = load %94 |
| %96:f32 = div %95, 10.0f |
| %97:ptr<function, f32, read_write> = access %data, 9i |
| %98:f32 = load %97 |
| %99:f32 = div %98, 10.0f |
| %100:ptr<function, f32, read_write> = access %data, 0i |
| %101:f32 = load %100 |
| %102:f32 = div %101, 10.0f |
| %103:vec4<f32> = construct %96, %99, %102, 1.0f |
| store %x_GLF_color, %103 |
| exit_if # if_7 |
| } |
| } |
| ret |
| } |
| } |
| %tint_symbol = @fragment func(%gl_FragCoord_param:vec4<f32> [@position]):main_out { |
| $B22: { |
| store %gl_FragCoord, %gl_FragCoord_param |
| %106:void = call %main_1 |
| %107:vec4<f32> = load %x_GLF_color |
| %108:main_out = construct %107 |
| ret %108 |
| } |
| } |
| |
| 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. * |
| ******************************************************************** |