blob: e68341c2a1cd745c7e94e519a0d2c9ffeea81d9a [file] [log] [blame]
SKIP: FAILED
#include <metal_stdlib>
using namespace metal;
thread half t = 0.0h;
half m() {
t = 1.0h;
return half(t);
}
void f() {
int v = tint_f16_to_i32(m());
}
int tint_f16_to_i32(half value) {
return select(2147483647, select((-2147483647 - 1), int(value), (value >= -65504.0h)), (value <= 65504.0h));
}
program_source:4:13: error: program scope variable must reside in constant address space
thread half t = 0.0h;
^
program_source:10:11: error: use of undeclared identifier 'tint_f16_to_i32'
int v = tint_f16_to_i32(m());
^