MCPcopy Create free account
hub / github.com/ARM-software/astc-encoder / float_to_float16

Function float_to_float16

Source/astcenc_vecmathlib_none_4.h:1017–1024  ·  view source on GitHub ↗

* @brief Return a float16 value for a float vector, using round-to-nearest. */

Source from the content-addressed store, hash-verified

1015 * @brief Return a float16 value for a float vector, using round-to-nearest.
1016 */
1017ASTCENC_SIMD_INLINE vint4 float_to_float16(vfloat4 a)
1018{
1019 return vint4(
1020 float_to_sf16(a.lane<0>()),
1021 float_to_sf16(a.lane<1>()),
1022 float_to_sf16(a.lane<2>()),
1023 float_to_sf16(a.lane<3>()));
1024}
1025
1026/**
1027 * @brief Return a float16 value for a float scalar, using round-to-nearest.

Callers

nothing calls this directly

Calls 2

float_to_sf16Function · 0.85
vint4Class · 0.70

Tested by

no test coverage detected