diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2021-03-24 12:58:56 +0300 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2021-04-13 13:55:34 +0300 |
commit | 3b22d722555ab88ff4a9181220bbfc3fa59b94ee (patch) | |
tree | 8b5f8b01f45abd7ba06db103396dab7925bfd72d /newlib/libm | |
parent | 642be00cdb5819b41bad4045de5fae395fffc2f5 (diff) |
fenv: drop Cygwin-specific implementation in favor of newlib code
Drop the Cygwin-specific fenv.cc and fenv.h file and use the equivalent
newlib functionality now, so we have at least one example of a user for
this new mechanism.
fenv.c: allow _feinitialise to be called from Cygwin startup code
fenv.h: add declarations for fegetprec and fesetprec for Cygwin only.
Fix a comment.
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'newlib/libm')
-rw-r--r-- | newlib/libm/machine/shared_x86/fenv.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/newlib/libm/machine/shared_x86/fenv.c b/newlib/libm/machine/shared_x86/fenv.c index ccc08e2d8..8d1f1ad7f 100644 --- a/newlib/libm/machine/shared_x86/fenv.c +++ b/newlib/libm/machine/shared_x86/fenv.c @@ -63,8 +63,10 @@ static inline bool use_sse(void) return false; } +#ifndef __CYGWIN__ /* forward declaration */ static void _feinitialise (void); +#endif /* This function enables traps for each of the exceptions as indicated by the parameter except. The individual exceptions are described in @@ -449,7 +451,10 @@ fesetprec (int prec) #endif /* Set up the FPU and SSE environment at the start of execution. */ -static void +#ifndef __CYGWIN__ +static +#endif +void _feinitialise (void) { extern fenv_t __fe_dfl_env; |