summary refs log tree commit diff
path: root/sysdeps/powerpc
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-10-31 23:32:56 +0000
committerUlrich Drepper <drepper@redhat.com>1999-10-31 23:32:56 +0000
commit63ae7b6309964400c6289d9030c7d336a33b304f (patch)
treeb4b63c3c08a2221de53048493b2c586a9aa79689 /sysdeps/powerpc
parentb4cbd37109d882aa052e7973684774eaa887071b (diff)
downloadglibc-63ae7b6309964400c6289d9030c7d336a33b304f.tar.gz
glibc-63ae7b6309964400c6289d9030c7d336a33b304f.tar.xz
glibc-63ae7b6309964400c6289d9030c7d336a33b304f.zip
Update.
	* Versions.def (libm): Add GLIBC_2.1.3.

	ISO C99 TR1 changes various fe* functions to return an error value.
	* math/Versions [GLIBC_2.1.3]: Add feclearexcept, fegetexceptflag,
	feraiseexcept, fesetexceptflag, fegetenv, fesetenv, and feupdateenv.
	* sysdeps/alpha/fpu/fclrexcpt.c: Return value and add alias.
	* sysdeps/alpha/fpu/fegetenv.c: Likewise.
	* sysdeps/alpha/fpu/fesetenv.c: Likewise.
	* sysdeps/alpha/fpu/feupdateenv.c: Likewise.
	* sysdeps/alpha/fpu/fgetexcptflg.c: Likewise.
	* sysdeps/alpha/fpu/fraiseexcpt.c: Likewise.
	* sysdeps/alpha/fpu/fsetexcptflg.c: Likewise.
	* sysdeps/arm/fpu/fclrexcpt.c: Likewise.
	* sysdeps/arm/fpu/fegetenv.c: Likewise.
	* sysdeps/arm/fpu/fesetenv.c: Likewise.
	* sysdeps/arm/fpu/fraiseexcpt.c: Likewise.
	* sysdeps/arm/fpu/fsetexcptflg.c: Likewise.
	* sysdeps/generic/fclrexcpt.c: Likewise.
	* sysdeps/generic/fegetenv.c: Likewise.
	* sysdeps/generic/fesetenv.c: Likewise.
	* sysdeps/generic/feupdateenv.c: Likewise.
	* sysdeps/generic/fgetexcptflg.c: Likewise.
	* sysdeps/generic/fraiseexcpt.c: Likewise.
	* sysdeps/generic/fsetexcptflg.c: Likewise.
	* sysdeps/i386/fpu/fclrexcpt.c: Likewise.
	* sysdeps/i386/fpu/fegetenv.c: Likewise.
	* sysdeps/i386/fpu/fesetenv.c: Likewise.
	* sysdeps/i386/fpu/feupdateenv.c: Likewise.
	* sysdeps/i386/fpu/fgetexcptflg.c: Likewise.
	* sysdeps/i386/fpu/fraiseexcpt.c: Likewise.
	* sysdeps/i386/fpu/fsetexcptflg.c: Likewise.
	* sysdeps/m68k/fpu/fclrexcpt.c: Likewise.
	* sysdeps/m68k/fpu/fegetenv.c: Likewise.
	* sysdeps/m68k/fpu/fesetenv.c: Likewise.
	* sysdeps/m68k/fpu/feupdateenv.c: Likewise.
	* sysdeps/m68k/fpu/fgetexcptflg.c: Likewise.
	* sysdeps/m68k/fpu/fraiseexcpt.c: Likewise.
	* sysdeps/m68k/fpu/fsetexcptflg.c: Likewise.
	* sysdeps/mips/fclrexcpt.c: Likewise.
	* sysdeps/mips/fegetenv.c: Likewise.
	* sysdeps/mips/fesetenv.c: Likewise.
	* sysdeps/mips/feupdateenv.c: Likewise.
	* sysdeps/mips/fgetexcptflg.c: Likewise.
	* sysdeps/powerpc/fclrexcpt.c: Likewise.
	* sysdeps/powerpc/fegetenv.c: Likewise.
	* sysdeps/powerpc/fesetenv.c: Likewise.
	* sysdeps/powerpc/feupdateenv.c: Likewise.
	* sysdeps/powerpc/fgetexcptflg.c: Likewise.
	* sysdeps/powerpc/fraiseexcpt.c: Likewise.
	* sysdeps/powerpc/fsetexcptflg.c: Likewise.
	* sysdeps/sparc/fpu/fclrexcpt.c: Likewise.
	* sysdeps/sparc/fpu/fegetenv.c: Likewise.
	* sysdeps/sparc/fpu/fesetenv.c: Likewise.
	* sysdeps/sparc/fpu/feupdateenv.c: Likewise.
	* sysdeps/sparc/fpu/fgetexcptflg.c: Likewise.
	* sysdeps/sparc/fpu/fraiseexcpt.c: Likewise.
	* sysdeps/sparc/fpu/fsetexcptflg.c: Likewise.
	* math/fenv.h: Adjust prototypes.: Likewise.
	* manual/arith.texi: Adjust documentation for these changes.

	* manual/arith.texi: Document feraiseexcept.

	* sysdeps/powerpc/fegetenv.c: Moved to...
	* sysdeps/powerpc/fpu/fegetenv.c: ...here.
	* sysdeps/powerpc/fegetround.c: Moved to...
	* sysdeps/powerpc/fpu/fegetround.c: ...here.
	* sysdeps/powerpc/feholdexcpt.c: Moved to...
	* sysdeps/powerpc/fpu/feholdexcpt.c: ...here.
	* sysdeps/powerpc/fesetenv.c: Moved to...
	* sysdeps/powerpc/fpu/fesetenv.c: ...here.
	* sysdeps/powerpc/fenv_libc.h: Moved to...
	* sysdeps/powerpc/fpu/fenv_libc.h: ...here.
	* sysdeps/powerpc/feupdateenv.c: Moved to...
	* sysdeps/powerpc/fpu/feupdateenv.c: ...here.
	* sysdeps/powerpc/fgetexcptflg.c: Moved to...
	* sysdeps/powerpc/fpu/fgetexcptflg.c: ...here.
	* sysdeps/powerpc/fraiseexcpt.c: Moved to...
	* sysdeps/powerpc/fpu/fraiseexcpt.c: ...here.
	* sysdeps/powerpc/fsetexcptflg.c: Moved to...
	* sysdeps/powerpc/fpu/fsetexcptflg.c: ...here.
	* sysdeps/powerpc/ftestexcept.c: Moved to...
	* sysdeps/powerpc/fpu/ftestexcept.c: ...here.
	* sysdeps/powerpc/fesetround.c: Moved to...
	* sysdeps/powerpc/fpu/fesetround.c: ...here
	* sysdeps/powerpc/fenv_const.c: Moved to...
	* sysdeps/powerpc/fpu/fenv_const.c: ...here.

1999-10-29  Jakub Jelinek  <jakub@redhat.com>

	* stdlib/longlong.h: Avoid UDIV_TIME redefinition.
	* sysdeps/sparc/sparc32/dl-machine.h: Fix loading of SPARC v8plus
	libraries from statically linked programs.
	* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h: POSIX 199309
	fix for sigaction on SPARC.
	Patches by David S. Miller <davem@redhat.com>.

	* sysdeps/unix/sysv/linux/sparc/sys/ucontext.h: Declare
	gregset_t and other required structures and defines for SPARC 64bit
	ABI as well, not only 32bit ABI.

1999-10-31  Andreas Jaeger  <aj@suse.de>

	* sysdeps/sparc/sparc64/fpu/bits/huge_val.h: Replace __USE_ISOC9X
	by __USE_ISOC99 and update comments.

	* math/complex.h: Update comments for ISO C99.
	* math/fenv.h: Likewise.
	* math/test-fenv.c: Likewise.
	* math/tgmath.h: Likewise.
	* libio/stdio.h: Likewise.
	* posix/sys/types.h: Likewise.
	* sysdeps/generic/inttypes.h: Likewise.
	* sysdeps/generic/stdint.h: Likewise.

1999-10-31  Ulrich Drepper  <drepper@cygnus.com>
Diffstat (limited to 'sysdeps/powerpc')
-rw-r--r--sysdeps/powerpc/fclrexcpt.c16
-rw-r--r--sysdeps/powerpc/fegetenv.c26
-rw-r--r--sysdeps/powerpc/fegetround.c29
-rw-r--r--sysdeps/powerpc/fesetenv.c26
-rw-r--r--sysdeps/powerpc/fesetround.c41
-rw-r--r--sysdeps/powerpc/feupdateenv.c37
-rw-r--r--sysdeps/powerpc/fpu/feholdexcpt.c (renamed from sysdeps/powerpc/feholdexcpt.c)0
-rw-r--r--sysdeps/powerpc/fpu/fenv_const.c (renamed from sysdeps/powerpc/fenv_const.c)0
-rw-r--r--sysdeps/powerpc/fpu/fenv_libc.h (renamed from sysdeps/powerpc/fenv_libc.h)0
-rw-r--r--sysdeps/powerpc/fpu/fgetexcptflg.c (renamed from sysdeps/powerpc/fgetexcptflg.c)12
-rw-r--r--sysdeps/powerpc/fpu/fraiseexcpt.c (renamed from sysdeps/powerpc/fraiseexcpt.c)12
-rw-r--r--sysdeps/powerpc/fpu/fsetexcptflg.c (renamed from sysdeps/powerpc/fsetexcptflg.c)12
-rw-r--r--sysdeps/powerpc/ftestexcept.c33
13 files changed, 38 insertions, 206 deletions
diff --git a/sysdeps/powerpc/fclrexcpt.c b/sysdeps/powerpc/fclrexcpt.c
index 47254fd384..4a4adbb5c4 100644
--- a/sysdeps/powerpc/fclrexcpt.c
+++ b/sysdeps/powerpc/fclrexcpt.c
@@ -1,5 +1,5 @@
 /* Clear given exceptions in current floating-point environment.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -20,8 +20,8 @@
 #include <fenv_libc.h>
 
 #undef feclearexcept
-void
-feclearexcept (int excepts)
+int
+__feclearexcept (int excepts)
 {
   fenv_union_t u;
 
@@ -29,9 +29,15 @@ feclearexcept (int excepts)
   u.fenv = fegetenv_register ();
 
   /* Clear the relevant bits.  */
-  u.l[1] = u.l[1] & ~((-((excepts) >> (31-FPSCR_VX) & 1) & FE_ALL_INVALID)
-		      | ((excepts) & FPSCR_STICKY_BITS));
+  u.l[1] = u.l[1] & ~((-(excepts >> (31 - FPSCR_VX) & 1) & FE_ALL_INVALID)
+		      | (excepts & FPSCR_STICKY_BITS));
 
   /* Put the new state in effect.  */
   fesetenv_register (u.fenv);
+
+  /* Success.  */
+  return 0;
 }
+strong_alias (__feclearexcept, __old_feclearexcept)
+symbol_version (__old_feclearexcept, feclearexcept, GLIBC_2.1);
+default_symbol_version (__feclearexcept, feclearexcept, GLIBC_2.1.3);
diff --git a/sysdeps/powerpc/fegetenv.c b/sysdeps/powerpc/fegetenv.c
deleted file mode 100644
index de778fa5a9..0000000000
--- a/sysdeps/powerpc/fegetenv.c
+++ /dev/null
@@ -1,26 +0,0 @@
-/* Store current floating-point environment.
-   Copyright (C) 1997 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <fenv_libc.h>
-
-void
-fegetenv (fenv_t *envp)
-{
-  *envp = fegetenv_register ();
-}
diff --git a/sysdeps/powerpc/fegetround.c b/sysdeps/powerpc/fegetround.c
deleted file mode 100644
index 3bb9fb49e0..0000000000
--- a/sysdeps/powerpc/fegetround.c
+++ /dev/null
@@ -1,29 +0,0 @@
-/* Return current rounding direction.
-   Copyright (C) 1997 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <fenv_libc.h>
-
-#undef fegetround
-int
-fegetround (void)
-{
-  int result;
-  asm ("mcrfs 7,7 ; mfcr %0" : "=r"(result) : : "cr7"); \
-  return result & 3;
-}
diff --git a/sysdeps/powerpc/fesetenv.c b/sysdeps/powerpc/fesetenv.c
deleted file mode 100644
index 136a835d21..0000000000
--- a/sysdeps/powerpc/fesetenv.c
+++ /dev/null
@@ -1,26 +0,0 @@
-/* Install given floating-point environment.
-   Copyright (C) 1997 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <fenv_libc.h>
-
-void
-fesetenv (const fenv_t *envp)
-{
-  fesetenv_register (*envp);
-}
diff --git a/sysdeps/powerpc/fesetround.c b/sysdeps/powerpc/fesetround.c
deleted file mode 100644
index 875c89768a..0000000000
--- a/sysdeps/powerpc/fesetround.c
+++ /dev/null
@@ -1,41 +0,0 @@
-/* Set current rounding direction.
-   Copyright (C) 1997 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <fenv_libc.h>
-
-int
-fesetround (int round)
-{
-  fenv_union_t u;
-
-  if ((unsigned int) round > 3)
-    return 0;
-
-  /* Get the current state.  */
-  u.fenv = fegetenv_register ();
-
-  /* Set the relevant bits.  */
-  u.l[1] = (u.l[1] & ~3)  |  (round & 3);
-
-  /* Put the new state in effect.  */
-  fesetenv_register (u.fenv);
-
-  return 1;
-}
diff --git a/sysdeps/powerpc/feupdateenv.c b/sysdeps/powerpc/feupdateenv.c
deleted file mode 100644
index 14fa6bbe4e..0000000000
--- a/sysdeps/powerpc/feupdateenv.c
+++ /dev/null
@@ -1,37 +0,0 @@
-/* Install given floating-point environment and raise exceptions.
-   Copyright (C) 1997 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <fenv_libc.h>
-
-void
-feupdateenv (const fenv_t *envp)
-{
-  fenv_union_t old, new;
-
-  /* Save the currently set exceptions.  */
-  new.fenv = *envp;
-  old.fenv = fegetenv_register ();
-
-  /* Copy the set exceptions from `old' to `new'.  */
-  new.l[1] = (new.l[1] & 0xE00000FF) | (old.l[1] & 0x1FFFFF00);
-
-  /* Atomically enable and raise (if appropriate) exceptions set in `new'. */
-  fesetenv_register (new.fenv);
-}
diff --git a/sysdeps/powerpc/feholdexcpt.c b/sysdeps/powerpc/fpu/feholdexcpt.c
index a75adbf49e..a75adbf49e 100644
--- a/sysdeps/powerpc/feholdexcpt.c
+++ b/sysdeps/powerpc/fpu/feholdexcpt.c
diff --git a/sysdeps/powerpc/fenv_const.c b/sysdeps/powerpc/fpu/fenv_const.c
index 506bd43df0..506bd43df0 100644
--- a/sysdeps/powerpc/fenv_const.c
+++ b/sysdeps/powerpc/fpu/fenv_const.c
diff --git a/sysdeps/powerpc/fenv_libc.h b/sysdeps/powerpc/fpu/fenv_libc.h
index 343be16fcb..343be16fcb 100644
--- a/sysdeps/powerpc/fenv_libc.h
+++ b/sysdeps/powerpc/fpu/fenv_libc.h
diff --git a/sysdeps/powerpc/fgetexcptflg.c b/sysdeps/powerpc/fpu/fgetexcptflg.c
index adbdfe22b9..280203a173 100644
--- a/sysdeps/powerpc/fgetexcptflg.c
+++ b/sysdeps/powerpc/fpu/fgetexcptflg.c
@@ -1,5 +1,5 @@
 /* Store current representation for exceptions.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -19,8 +19,8 @@
 
 #include <fenv_libc.h>
 
-void
-fegetexceptflag (fexcept_t *flagp, int excepts)
+int
+__fegetexceptflag (fexcept_t *flagp, int excepts)
 {
   fenv_union_t u;
 
@@ -29,4 +29,10 @@ fegetexceptflag (fexcept_t *flagp, int excepts)
 
   /* Return (all of) it.  */
   *flagp = u.l[1];
+
+  /* Success.  */
+  return 0;
 }
+strong_alias (__fegetexceptflag, __old_fegetexceptflag)
+symbol_version (__old_fegetexceptflag, fegetexceptflag, GLIBC_2.1);
+default_symbol_version (__fegetexceptflag, fegetexceptflag, GLIBC_2.1.3);
diff --git a/sysdeps/powerpc/fraiseexcpt.c b/sysdeps/powerpc/fpu/fraiseexcpt.c
index 39e3fbd6bf..b72f7cb797 100644
--- a/sysdeps/powerpc/fraiseexcpt.c
+++ b/sysdeps/powerpc/fpu/fraiseexcpt.c
@@ -1,5 +1,5 @@
 /* Raise given exceptions.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -20,8 +20,8 @@
 #include <fenv_libc.h>
 
 #undef feraiseexcept
-void
-feraiseexcept (int excepts)
+int
+__feraiseexcept (int excepts)
 {
   fenv_union_t u;
 
@@ -50,4 +50,10 @@ feraiseexcept (int excepts)
 	 case and raise FE_INVALID_SNAN instead.  */
       && !fetestexcept (FE_INVALID))
     set_fpscr_bit (FPSCR_VXSNAN);
+
+  /* Success.  */
+  return 0;
 }
+strong_alias (__feraiseexcept, __old_feraiseexcept)
+symbol_version (__old_feraiseexcept, feraiseexcept, GLIBC_2.1);
+default_symbol_version (__feraiseexcept, feraiseexcept, GLIBC_2.1.3);
diff --git a/sysdeps/powerpc/fsetexcptflg.c b/sysdeps/powerpc/fpu/fsetexcptflg.c
index 347035e9d2..9ce59ac320 100644
--- a/sysdeps/powerpc/fsetexcptflg.c
+++ b/sysdeps/powerpc/fpu/fsetexcptflg.c
@@ -1,5 +1,5 @@
 /* Set floating-point environment exception handling.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -19,8 +19,8 @@
 
 #include <fenv_libc.h>
 
-void
-fesetexceptflag (const fexcept_t *flagp, int excepts)
+int
+__fesetexceptflag (const fexcept_t *flagp, int excepts)
 {
   fenv_union_t u;
   fexcept_t flag;
@@ -45,4 +45,10 @@ fesetexceptflag (const fexcept_t *flagp, int excepts)
   /* Deal with FE_INVALID_SOFTWARE not being implemented on some chips.  */
   if (flag & FE_INVALID)
     feraiseexcept(FE_INVALID);
+
+  /* Success.  */
+  return 0;
 }
+strong_alias (__fesetexceptflag, __old_fesetexceptflag)
+symbol_version (__old_fesetexceptflag, fesetexceptflag, GLIBC_2.1);
+default_symbol_version (__fesetexceptflag, fesetexceptflag, GLIBC_2.1.3);
diff --git a/sysdeps/powerpc/ftestexcept.c b/sysdeps/powerpc/ftestexcept.c
deleted file mode 100644
index 6cb8dd5e28..0000000000
--- a/sysdeps/powerpc/ftestexcept.c
+++ /dev/null
@@ -1,33 +0,0 @@
-/* Test exception in current environment.
-   Copyright (C) 1997 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <fenv_libc.h>
-
-int
-fetestexcept (int excepts)
-{
-  fenv_union_t u;
-
-  /* Get the current state.  */
-  u.fenv = fegetenv_register ();
-
-  /* The FE_INVALID bit is dealt with correctly by the hardware, so we can
-     just:  */
-  return u.l[1] & excepts;
-}