Functions for conversion between BFloat16 (16-bit Brain Floating Point) and 32-bit Floating Point numbers and other. More...
Functions | |
SIMD_API void | SimdFloat32ToBFloat16 (const float *src, size_t size, uint16_t *dst) |
Converts numbers in the array from 32-bit float to 16-bit bfloat format. More... | |
SIMD_API void | SimdBFloat16ToFloat32 (const uint16_t *src, size_t size, float *dst) |
Converts numbers in the array from 16-bit bfloat to 32-bit float format. More... | |
Detailed Description
Functions for conversion between BFloat16 (16-bit Brain Floating Point) and 32-bit Floating Point numbers and other.
Function Documentation
◆ SimdFloat32ToBFloat16()
void SimdFloat32ToBFloat16 | ( | const float * | src, |
size_t | size, | ||
uint16_t * | dst | ||
) |
Converts numbers in the array from 32-bit float to 16-bit bfloat format.
- Parameters
-
[in] src - a pointer to the input array with 32-bit float point numbers. [in] size - a size of input and output array. [out] dst - a pointer to the output array with 16-bit bfloat point numbers.
◆ SimdBFloat16ToFloat32()
void SimdBFloat16ToFloat32 | ( | const uint16_t * | src, |
size_t | size, | ||
float * | dst | ||
) |
Converts numbers in the array from 16-bit bfloat to 32-bit float format.
- Parameters
-
[in] src - a pointer to the input array with 16-bit bfloat point numbers. [in] size - a size of input and output array. [out] dst - a pointer to the output array with 32-bit float point numbers.