blob: 666d9ffaef6e1111f0d05cdfa4791eb2f10af671 [file] [log] [blame]
uint2 tint_bitcast_from_f16(vector<float16_t, 4> src) {
uint4 r = f32tof16(float4(src));
return uint2(((r.x & 65535u) | ((r.y & 65535u) << 16u)), ((r.z & 65535u) | ((r.w & 65535u) << 16u)));
}
[numthreads(1, 1, 1)]
void f() {
vector<float16_t, 4> a = vector<float16_t, 4>(float16_t(1.0h), float16_t(2.0h), float16_t(3.0h), float16_t(-4.0h));
uint2 b = tint_bitcast_from_f16(a);
}