7 #if LDBL_MANT_DIG == 53 && LDBL_MAX_EXP == 1024
8 #elif LDBL_MANT_DIG == 64 && LDBL_MAX_EXP == 16384
18 #elif LDBL_MANT_DIG == 113 && LDBL_MAX_EXP == 16384
29 #error Unsupported long double representation
33 // FIXME: hacks to make freebsd+openbsd long double code happy
35 // union and macros for freebsd
37 #if LDBL_MANT_DIG == 64 && LDBL_MAX_EXP == 16384
55 #define LDBL_MANL_SIZE 32
56 #define LDBL_MANH_SIZE 32
57 #define LDBL_NBIT (1ull << LDBL_MANH_SIZE-1)
58 #undef LDBL_IMPLICIT_NBIT
59 #define mask_nbit_l(u) ((u).bits.manh &= ~LDBL_NBIT)
61 #elif LDBL_MANT_DIG == 113 && LDBL_MAX_EXP == 16384
64 //#define LDBL_MAX 1.189731495357231765085759326628007016E+4932L
65 #define LDBL_MAX 0x1.ffffffffffffffffffffffffffffp+16383
66 #define LDBL_MAX_EXP 16384
67 #define LDBL_HAS_INFINITY 1
68 //#define LDBL_MIN 3.362103143112093506262677817321752603E-4932L
69 #define LDBL_MIN 0x1p-16382
70 #define LDBL_HAS_QUIET_NAN 1
71 #define LDBL_HAS_DENORM 1
72 //#define LDBL_EPSILON 1.925929944387235853055977942584927319E-34L
73 #define LDBL_EPSILON 0x1p-112
74 #define LDBL_MANT_DIG 113
75 #define LDBL_MIN_EXP (-16381)
76 #define LDBL_MAX_10_EXP 4932
77 #define LDBL_DENORM_MIN 0x0.0000000000000000000000000001p-16381
78 #define LDBL_MIN_10_EXP (-4931)
97 #define LDBL_MANL_SIZE 64
98 #define LDBL_MANH_SIZE 48
99 #define LDBL_NBIT (1ull << LDBL_MANH_SIZE)
100 #define LDBL_IMPLICIT_NBIT 1
101 #define mask_nbit_l(u)
106 // macros for openbsd
108 #define GET_LDOUBLE_WORDS(se,mh,ml, f) do{ \
109 union IEEEl2bits u; \
111 (se) = u.xbits.expsign; \
112 (mh) = u.bits.manh; \
113 (ml) = u.bits.manl; \
116 #define SET_LDOUBLE_WORDS(f, se,mh,ml) do{ \
117 union IEEEl2bits u; \
118 u.xbits.expsign = (se); \
119 u.bits.manh = (mh); \
120 u.bits.manl = (ml); \
124 #define GET_LDOUBLE_EXP(se, f) do{ \
125 union IEEEl2bits u; \
127 (se) = u.xbits.expsign; \
130 #define SET_LDOUBLE_EXP(f, se) do{ \
131 union IEEEl2bits u; \
133 u.xbits.expsign = (se); \