add link to paper for single/half float conversions

This commit is contained in:
Alex Shinn 2024-06-01 22:18:16 +09:00
parent f1df493c32
commit b1a370b218

1
sexp.c
View file

@ -3204,6 +3204,7 @@ static float int_as_float(const unsigned int n) {
return x.flonum; return x.flonum;
} }
/* https://arxiv.org/abs/2112.08926 */
double sexp_half_to_double(unsigned short x) { double sexp_half_to_double(unsigned short x) {
unsigned int e = (x&0x7C00)>>10, unsigned int e = (x&0x7C00)>>10,
m = (x&0x03FF)<<13, m = (x&0x03FF)<<13,