* @brief Return a float value for a float16 vector. */
| 919 | * @brief Return a float value for a float16 vector. |
| 920 | */ |
| 921 | ASTCENC_SIMD_INLINE vfloat4 float16_to_float(vint4 a) |
| 922 | { |
| 923 | // Convert each 32-bit float pattern to a 16-bit pattern |
| 924 | uint32x4_t u32 = vreinterpretq_u32_s32(a.m); |
| 925 | uint16x4_t u16 = vmovn_u32(u32); |
| 926 | float16x4_t f16 = vreinterpret_f16_u16(u16); |
| 927 | |
| 928 | // Generate float16 value |
| 929 | return vfloat4(vcvt_f32_f16(f16)); |
| 930 | } |
| 931 | |
| 932 | /** |
| 933 | * @brief Return a float value for a float16 scalar. |