Changeset View
Changeset View
Standalone View
Standalone View
lib/libc/riscv/_fpmath.h
Show All 40 Lines | struct { | ||||
unsigned int expsign :16; | unsigned int expsign :16; | ||||
} xbits; | } xbits; | ||||
}; | }; | ||||
#define LDBL_NBIT 0 | #define LDBL_NBIT 0 | ||||
#define LDBL_IMPLICIT_NBIT | #define LDBL_IMPLICIT_NBIT | ||||
#define mask_nbit_l(u) ((void)0) | #define mask_nbit_l(u) ((void)0) | ||||
#define LDBL_MANH_SIZE 20 | |||||
#define LDBL_MANL_SIZE 32 | |||||
#define LDBL_TO_ARRAY32(u, a) do { \ | |||||
(a)[0] = (uint32_t)(u).bits.manl; \ | |||||
(a)[1] = (uint32_t)(u).bits.manh; \ | |||||
} while(0) | |||||
/* | |||||
* TODO: Due to compiler problem we are temporary using | |||||
* LDBL_PREC == 53. Use code below for LDBL_PREC == 113 | |||||
*/ | |||||
#if 0 | |||||
#define LDBL_MANH_SIZE 48 | #define LDBL_MANH_SIZE 48 | ||||
#define LDBL_MANL_SIZE 64 | #define LDBL_MANL_SIZE 64 | ||||
#define LDBL_TO_ARRAY32(u, a) do { \ | #define LDBL_TO_ARRAY32(u, a) do { \ | ||||
(a)[0] = (uint32_t)(u).bits.manl; \ | (a)[0] = (uint32_t)(u).bits.manl; \ | ||||
(a)[1] = (uint32_t)((u).bits.manl >> 32); \ | (a)[1] = (uint32_t)((u).bits.manl >> 32); \ | ||||
(a)[2] = (uint32_t)(u).bits.manh; \ | (a)[2] = (uint32_t)(u).bits.manh; \ | ||||
(a)[3] = (uint32_t)((u).bits.manh >> 32); \ | (a)[3] = (uint32_t)((u).bits.manh >> 32); \ | ||||
} while(0) | } while(0) | ||||
#endif |