diff options
Diffstat (limited to 'libc/sysdeps/linux/arm/bits')
-rw-r--r-- | libc/sysdeps/linux/arm/bits/endian.h | 2 | ||||
-rw-r--r-- | libc/sysdeps/linux/arm/bits/fenv.h | 41 | ||||
-rw-r--r-- | libc/sysdeps/linux/arm/bits/setjmp.h | 4 |
3 files changed, 46 insertions, 1 deletions
diff --git a/libc/sysdeps/linux/arm/bits/endian.h b/libc/sysdeps/linux/arm/bits/endian.h index 4f60bd7d2..27946cdee 100644 --- a/libc/sysdeps/linux/arm/bits/endian.h +++ b/libc/sysdeps/linux/arm/bits/endian.h @@ -12,7 +12,7 @@ /* FPA floating point units are always big-endian, irrespective of the CPU endianness. VFP floating point units use the same endianness as the rest of the system. */ -#ifdef __VFP_FP__ +#if defined __VFP_FP__ || defined __MAVERICK__ # define __FLOAT_WORD_ORDER __BYTE_ORDER #else # define __FLOAT_WORD_ORDER __BIG_ENDIAN diff --git a/libc/sysdeps/linux/arm/bits/fenv.h b/libc/sysdeps/linux/arm/bits/fenv.h index 7bd242385..3764d7749 100644 --- a/libc/sysdeps/linux/arm/bits/fenv.h +++ b/libc/sysdeps/linux/arm/bits/fenv.h @@ -20,6 +20,45 @@ # error "Never use <bits/fenv.h> directly; include <fenv.h> instead." #endif +#ifdef __MAVERICK__ + +/* Define bits representing exceptions in the FPU status word. */ +enum + { + FE_INVALID = 1, +#define FE_INVALID FE_INVALID + FE_OVERFLOW = 4, +#define FE_OVERFLOW FE_OVERFLOW + FE_UNDERFLOW = 8, +#define FE_UNDERFLOW FE_UNDERFLOW + FE_INEXACT = 16, +#define FE_INEXACT FE_INEXACT + }; + +/* Amount to shift by to convert an exception to a mask bit. */ +#define FE_EXCEPT_SHIFT 5 + +/* All supported exceptions. */ +#define FE_ALL_EXCEPT \ + (FE_INVALID | FE_OVERFLOW | FE_UNDERFLOW | FE_INEXACT) + +/* IEEE rounding modes. */ +enum + { + FE_TONEAREST = 0, +#define FE_TONEAREST FE_TONEAREST + FE_TOWARDZERO = 0x400, +#define FE_TOWARDZERO FE_TOWARDZERO + FE_DOWNWARD = 0x800, +#define FE_DOWNWARD FE_DOWNWARD + FE_UPWARD = 0xc00, +#define FE_UPWARD FE_UPWARD + }; + +#define FE_ROUND_MASK (FE_UPWARD) + +#else /* !__MAVERICK__ */ + /* Define bits representing exceptions in the FPU status word. */ enum { @@ -44,6 +83,8 @@ enum modes exist, but you have to encode them in the actual instruction. */ #define FE_TONEAREST 0 +#endif /* __MAVERICK__ */ + /* Type representing exception flags. */ typedef unsigned long int fexcept_t; diff --git a/libc/sysdeps/linux/arm/bits/setjmp.h b/libc/sysdeps/linux/arm/bits/setjmp.h index dd8524303..e1d51468f 100644 --- a/libc/sysdeps/linux/arm/bits/setjmp.h +++ b/libc/sysdeps/linux/arm/bits/setjmp.h @@ -25,8 +25,12 @@ #ifndef _ASM /* Jump buffer contains v1-v6, sl, fp, sp and pc. Other registers are not saved. */ +#ifdef __MAVERICK__ +typedef int __jmp_buf[34]; +#else typedef int __jmp_buf[22]; #endif +#endif #define __JMP_BUF_SP 20 |