SPIR-V doesn't have any 8-bit types, so WSL can't either

Created attachment 322680 [details] Patch

According to https://msdn.microsoft.com/en-us/library/bb509646(v=vs.85).aspx and https://www.khronos.org/registry/spir-v/specs/1.2/SPIRV.html#_a_id_capability_a_capability - HLSL doesn't have 64-bit int types, and they're optional in SPIR-V - HLSL requires half-precision floating point numbers, and they're optional in SPIR-V - HLSL requires double-precision floating point numbers, and they're optional in SPIR-V (and already implemented in WSL)

(In reply to Myles C. Maxfield from comment #0) > SPIR-V doesn't have any 8-bit types, so WSL can't either I think you should be a bit more precise about this. If it was merely that SPIR-V didn't support 8-bit types, then we should just say that we lower 8-bit types to 32-bit types on the fly. This is trivial: - Any 8-bit math operation is expressible in terms of 32-bit math operations. Most 8-bit math operations lower to exactly one 32-bit math operation and then you ignore the high bits. The only exceptions are right shifts, division, and modulo. - 8-bit fields in memory can be packed into 32-bit fields, and then extracted using shifts and masking. So, it's not correct to say that WSL "can't" have 8-bit types. It totally can. Maybe we don't want it to have 8-bit types, but then that's a different issue.

Migrated to https://github.com/gpuweb/WHLSL/issues/165

Comment on attachment 322680 [details] Patch Unflagging and obsoleting, since this has been WONTFIXEd.