blob: 8f307da3b071072d90e51ce1527839e7b516fc04 [file] [log] [blame]
SKIP: FAILED
../../src/tint/lang/msl/writer/printer/printer.cc:500 internal compiler error: strided_arr = struct @align(4) {
el:i32 @offset(0)
}
buf0 = struct @align(4) {
x_GLF_uniform_int_values:array<strided_arr, 3> @offset(0)
}
main_out = struct @align(16) {
x_GLF_color_1:vec4<f32> @offset(0), @location(0)
}
$B1: { # root
%x_6: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
%5:ptr<uniform, i32, read> = access %x_6, 0u, 2i, 0u
%6:i32 = load %5
store %a, %6
loop [b: $B3, c: $B4] { # loop_1
$B3: { # body
%7:i32 = load %a
%8:bool = gte %7, 0i
if %8 [t: $B5, f: $B6] { # if_1
$B5: { # true
exit_if # if_1
}
$B6: { # false
exit_loop # loop_1
}
}
%9:i32 = load %a
%10:i32 = call %tint_div_i32, %9, 2i
%12:i32 = sub %10, 1i
store %a, %12
continue # -> $B4
}
$B4: { # continuing
next_iteration # -> $B3
}
}
%13:i32 = load %a
%14:ptr<uniform, i32, read> = access %x_6, 0u, 0i, 0u
%15:i32 = load %14
%16:i32 = negation %15
%17:bool = eq %13, %16
if %17 [t: $B7, f: $B8] { # if_2
$B7: { # true
%18:ptr<uniform, i32, read> = access %x_6, 0u, 0i, 0u
%19:i32 = load %18
%20:f32 = convert %19
%21:f32 = let %20
%22:ptr<uniform, i32, read> = access %x_6, 0u, 1i, 0u
%23:i32 = load %22
%24:f32 = convert %23
%25:f32 = let %24
%26:ptr<uniform, i32, read> = access %x_6, 0u, 1i, 0u
%27:i32 = load %26
%28:f32 = convert %27
%29:f32 = let %28
%30:ptr<uniform, i32, read> = access %x_6, 0u, 0i, 0u
%31:i32 = load %30
%32:f32 = convert %31
%33:vec4<f32> = construct %21, %25, %29, %32
store %x_GLF_color, %33
exit_if # if_2
}
$B8: { # false
%34:ptr<uniform, i32, read> = access %x_6, 0u, 1i, 0u
%35:i32 = load %34
%36:f32 = convert %35
%37:vec4<f32> = construct %36
store %x_GLF_color, %37
exit_if # if_2
}
}
ret
}
}
%tint_symbol = @fragment func():main_out {
$B9: {
%39:void = call %main_1
%40:vec4<f32> = load %x_GLF_color
%41:main_out = construct %40
ret %41
}
}
%tint_div_i32 = func(%lhs:i32, %rhs:i32):i32 {
$B10: {
%44:bool = eq %rhs, 0i
%45:bool = eq %lhs, -2147483648i
%46:bool = eq %rhs, -1i
%47:bool = and %45, %46
%48:bool = or %44, %47
%49:i32 = select %rhs, 1i, %48
%50:i32 = div %lhs, %49
ret %50
}
}
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. *
********************************************************************