summaryrefslogtreecommitdiffstats
path: root/lib/libc/ia64/_fpmath.h
diff options
context:
space:
mode:
authordas <das@FreeBSD.org>2003-04-05 22:10:13 +0000
committerdas <das@FreeBSD.org>2003-04-05 22:10:13 +0000
commit2d9148b622967fe103f5945f10d5c6917368dec6 (patch)
tree5a3e884c339a9c9b47d7762f22425febdfd1f2f3 /lib/libc/ia64/_fpmath.h
parent67eff66578dc776122f2e5cb24ff0bc1a57dda7b (diff)
downloadFreeBSD-src-2d9148b622967fe103f5945f10d5c6917368dec6.zip
FreeBSD-src-2d9148b622967fe103f5945f10d5c6917368dec6.tar.gz
Add __ldtoa(), a wrapper around gdtoa() to make it look like dtoa().
In support of this, add some MD macros to assist in converting long doubles to the format expected by gdtoa(). Reviewed by: silence on standards@
Diffstat (limited to 'lib/libc/ia64/_fpmath.h')
-rw-r--r--lib/libc/ia64/_fpmath.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/libc/ia64/_fpmath.h b/lib/libc/ia64/_fpmath.h
index 33e6a32..5d7a36b 100644
--- a/lib/libc/ia64/_fpmath.h
+++ b/lib/libc/ia64/_fpmath.h
@@ -53,3 +53,8 @@ union IEEEl2bits {
#else /* _BIG_ENDIAN */
#define mask_nbit_l(u) ((u).bits.manh &= 0xffffff7f)
#endif
+
+#define LDBL_TO_ARRAY32(u, a) do { \
+ (a)[0] = (uint32_t)(u).bits.manl; \
+ (a)[1] = (uint32_t)(u).bits.manh; \
+} while(0)
OpenPOWER on IntegriCloud