blob: 5ec16e652684af1c8b3f2ac15c19865a648a7335 [file] [log] [blame]
#include <metal_stdlib>
using namespace metal;
struct tint_module_vars_struct {
thread half* t;
};
half2 m(tint_module_vars_struct tint_module_vars) {
(*tint_module_vars.t) = 1.0h;
return half2((*tint_module_vars.t));
}
int2 tint_v2f16_to_v2i32(half2 value) {
return select(int2(2147483647), select(int2((-2147483647 - 1)), int2(value), (value >= half2(-65504.0h))), (value <= half2(65504.0h)));
}
void f(tint_module_vars_struct tint_module_vars) {
int2 v = tint_v2f16_to_v2i32(m(tint_module_vars));
}