blob: 4531c5af1cf8a87efe13c0c7bf345b71ea74d5c1 [file] [log] [blame]
SKIP: FAILED
../../src/tint/lang/msl/writer/printer/printer.cc:500 internal compiler error: buf0 = struct @align(4) {
one:i32 @offset(0)
}
S = struct @align(4) {
arr:array<i32, 2> @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)
%x_GLF_color:ptr<private, vec4<f32>, read_write> = var
}
%func_struct_S_i1_2_1_i1_ = func(%s:ptr<function, S, read_write>, %x:ptr<function, i32, read_write>):i32 {
$B2: {
%6:ptr<function, i32, read_write> = access %s, 0u, 1i
%7:i32 = load %x
%8:i32 = add %7, 1i
store %6, %8
%9:ptr<uniform, i32, read> = access %x_9, 0u
%10:i32 = load %9
%11:ptr<function, i32, read_write> = access %s, 0u, %10
%12:i32 = load %11
%13:i32 = load %x
%14:bool = eq %12, %13
if %14 [t: $B3] { # if_1
$B3: { # true
ret -1i
}
}
%15:i32 = load %x
%x_21:i32 = let %15
ret %x_21
}
}
%main_1 = func():void {
$B4: {
%a:ptr<function, i32, read_write> = var
%i:ptr<function, i32, read_write> = var
%j:ptr<function, i32, read_write> = var
%s_1:ptr<function, S, read_write> = var
%param:ptr<function, S, read_write> = var
%param_1:ptr<function, i32, read_write> = var
store %a, 0i
store %i, 0i
loop [b: $B5, c: $B6] { # loop_1
$B5: { # body
%24:i32 = load %i
%25:ptr<uniform, i32, read> = access %x_9, 0u
%26:i32 = load %25
%27:i32 = add 2i, %26
%28:bool = lt %24, %27
if %28 [t: $B7, f: $B8] { # if_2
$B7: { # true
exit_if # if_2
}
$B8: { # false
exit_loop # loop_1
}
}
store %j, 0i
loop [b: $B9, c: $B10] { # loop_2
$B9: { # body
%29:i32 = load %j
%30:ptr<uniform, i32, read> = access %x_9, 0u
%31:i32 = load %30
%32:i32 = add 3i, %31
%33:bool = lt %29, %32
if %33 [t: $B11, f: $B12] { # if_3
$B11: { # true
exit_if # if_3
}
$B12: { # false
exit_loop # loop_2
}
}
%34:i32 = load %i
%x_28:i32 = let %34
%36:i32 = load %j
%x_29:i32 = let %36
%38:S = load %s_1
store %param, %38
%39:i32 = add %x_28, %x_29
store %param_1, %39
%40:i32 = call %func_struct_S_i1_2_1_i1_, %param, %param_1
%x_31:i32 = let %40
%42:i32 = load %a
%43:i32 = add %42, %x_31
store %a, %43
continue # -> $B10
}
$B10: { # continuing
%44:i32 = load %j
%45:i32 = add %44, 1i
store %j, %45
next_iteration # -> $B9
}
}
continue # -> $B6
}
$B6: { # continuing
%46:i32 = load %i
%47:i32 = add %46, 1i
store %i, %47
next_iteration # -> $B5
}
}
%48:i32 = load %a
%49:bool = eq %48, 30i
if %49 [t: $B13, f: $B14] { # if_4
$B13: { # true
store %x_GLF_color, vec4<f32>(1.0f, 0.0f, 0.0f, 1.0f)
exit_if # if_4
}
$B14: { # false
store %x_GLF_color, vec4<f32>(0.0f)
exit_if # if_4
}
}
ret
}
}
%tint_symbol = @fragment func():main_out {
$B15: {
%51:void = call %main_1
%52:vec4<f32> = load %x_GLF_color
%53:main_out = construct %52
ret %53
}
}
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. *
********************************************************************