musl: patch riscv bits/fenv.h for soft float

This commit is contained in:
Alex Rønne Petersen 2026-01-16 13:29:34 +01:00
parent 171b104640
commit 081888286b
No known key found for this signature in database
2 changed files with 12 additions and 2 deletions

View file

@ -1,3 +1,7 @@
#ifdef __riscv_float_abi_soft
#define FE_ALL_EXCEPT 0
#define FE_TONEAREST 0
#else
#define FE_INVALID 16
#define FE_DIVBYZERO 8
#define FE_OVERFLOW 4
@ -10,8 +14,9 @@
#define FE_DOWNWARD 2
#define FE_UPWARD 3
#define FE_TOWARDZERO 1
#endif
typedef unsigned int fexcept_t;
typedef unsigned int fenv_t;
#define FE_DFL_ENV ((const fenv_t *) -1)
#define FE_DFL_ENV ((const fenv_t *) -1)

View file

@ -1,3 +1,7 @@
#ifdef __riscv_float_abi_soft
#define FE_ALL_EXCEPT 0
#define FE_TONEAREST 0
#else
#define FE_INVALID 16
#define FE_DIVBYZERO 8
#define FE_OVERFLOW 4
@ -10,8 +14,9 @@
#define FE_DOWNWARD 2
#define FE_UPWARD 3
#define FE_TOWARDZERO 1
#endif
typedef unsigned int fexcept_t;
typedef unsigned int fenv_t;
#define FE_DFL_ENV ((const fenv_t *) -1)
#define FE_DFL_ENV ((const fenv_t *) -1)