I want to use half-precision arithmetic on Raspberry pi 3. I installed clang compiler to use _Float16 data type (which is for 16-bit arithmetic purpose).
I was wondering is there any library for half-precision mathematic functions? (like <quadmath.h> for quadruple-precision numbers)
DuckDuckGo is your friend ;-) : http://half.sourceforge.net/
I already saw this link but I think this library is for software support of half-precision number? isn't it?
Right. Raspi 3 (Cortex-A53) has no HW support for half-precision floating point. FP16 was added in Armv8.2 and can be found in Cortex-A76 AFAIK.
Ok. so is there any half-precision math library that should be used for Cortex-A76?
What do you expect? FP16 version of sinf/cosf? Doesn't clang provide it?
I want to use all mathematic functions for FP16 numbers? the functions which are included in <math.h> are in single and double formats so clang doesn't provide them for FP16.
according to my research when ARMv8.2-FP16 is implemented, ARMV8 (Cortex-A53) supports half-precision data type for data processing in hardware. Am I right?
According the TRM CA53 supports only conversion:
[23:20] SIMDHP Indicates whether the Advanced SIMD and Floating-point extension supports half-precision floating-point conversion operations:0x1 Implemented.
View all questions in Cortex-A / A-Profile forum