diff options
Diffstat (limited to 'lib/libc/arm/_fpmath.h')
-rw-r--r-- | lib/libc/arm/_fpmath.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/lib/libc/arm/_fpmath.h b/lib/libc/arm/_fpmath.h index 98d7832..b0ce8f4 100644 --- a/lib/libc/arm/_fpmath.h +++ b/lib/libc/arm/_fpmath.h @@ -26,15 +26,26 @@ * $FreeBSD$ */ +#if defined(__VFP_FP__) +#define _IEEE_WORD_ORDER _BYTE_ORDER +#else +#define _IEEE_WORD_ORDER _BIG_ENDIAN +#endif + union IEEEl2bits { long double e; struct { -#ifndef __ARMEB__ +#if _BYTE_ORDER == _LITTLE_ENDIAN +#if _IEEE_WORD_ORDER == _LITTLE_ENDIAN unsigned int manl :32; +#endif unsigned int manh :20; unsigned int exp :11; unsigned int sign :1; -#else +#if _IEEE_WORD_ORDER == _BIG_ENDIAN + unsigned int manl :32; +#endif +#else /* _BYTE_ORDER == _LITTLE_ENDIAN */ unsigned int sign :1; unsigned int exp :11; unsigned int manh :20; |