]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Use floor functions not __floor functions in glibc libm.
authorJoseph Myers <joseph@codesourcery.com>
Fri, 14 Sep 2018 13:09:01 +0000 (13:09 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Fri, 14 Sep 2018 13:09:01 +0000 (13:09 +0000)
Similar to the changes that were made to call sqrt functions directly
in glibc, instead of __ieee754_sqrt variants, so that the compiler
could inline them automatically without needing special inline
definitions in lots of math_private.h headers, this patch makes libm
code call floor functions directly instead of __floor variants,
removing the inlines / macros for x86_64 (SSE4.1) and powerpc
(POWER5).

The redirection used to ensure that __ieee754_sqrt does still get
called when the compiler doesn't inline a built-in function expansion
is refactored so it can be applied to other functions; the refactoring
is arranged so it's not limited to unary functions either (it would be
reasonable to use this mechanism for copysign - removing the inline in
math_private_calls.h but also eliminating unnecessary local PLT entry
use in the cases (powerpc soft-float and e500v1, for IBM long double)
where copysign calls don't get inlined).

The point of this change is that more architectures can get floor
calls inlined where they weren't previously (AArch64, for example),
without needing special inline definitions in their math_private.h,
and existing such definitions in math_private.h headers can be
removed.

Note that it's possible that in some cases an inline may be used where
an IFUNC call was previously used - this is the case on x86_64, for
example.  I think the direct calls to floor are still appropriate; if
there's any significant performance cost from inline SSE2 floor
instead of an IFUNC call ending up with SSE4.1 floor, that indicates
that either the function should be doing something else that's faster
than using floor at all, or it should itself have IFUNC variants, or
that the compiler choice of inlining for generic tuning should change
to allow for the possibility that, by not inlining, an SSE4.1 IFUNC
might be called at runtime - but not that glibc should avoid calling
floor internally.  (After all, all the same considerations would apply
to any user program calling floor, where it might either be inlined or
left as an out-of-line call allowing for a possible IFUNC.)

Tested for x86_64, and with build-many-glibcs.py.

* include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ &&
__FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (MATH_REDIRECT):
New macro.
[!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
&& !NO_MATH_REDIRECT] (MATH_REDIRECT_LDBL): Likewise.
[!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
&& !NO_MATH_REDIRECT] (MATH_REDIRECT_F128): Likewise.
[!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
&& !NO_MATH_REDIRECT] (MATH_REDIRECT_UNARY_ARGS): Likewise.
[!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
&& !NO_MATH_REDIRECT] (sqrt): Redirect using MATH_REDIRECT.
[!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
&& !NO_MATH_REDIRECT] (floor): Likewise.
* sysdeps/aarch64/fpu/s_floor.c: Define NO_MATH_REDIRECT before
header inclusion.
* sysdeps/aarch64/fpu/s_floorf.c: Likewise.
* sysdeps/ieee754/dbl-64/s_floor.c: Likewise.
* sysdeps/ieee754/dbl-64/wordsize-64/s_floor.c: Likewise.
* sysdeps/ieee754/float128/s_floorf128.c: Likewise.
* sysdeps/ieee754/flt-32/s_floorf.c: Likewise.
* sysdeps/ieee754/ldbl-128/s_floorl.c: Likewise.
* sysdeps/ieee754/ldbl-128ibm/s_floorl.c: Likewise.
* sysdeps/m68k/m680x0/fpu/s_floor_template.c: Likewise.
* sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floor.c: Likewise.
* sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floorf.c: Likewise.
* sysdeps/powerpc/powerpc64/fpu/multiarch/s_floor.c: Likewise.
* sysdeps/powerpc/powerpc64/fpu/multiarch/s_floorf.c: Likewise.
* sysdeps/riscv/rv64/rvd/s_floor.c: Likewise.
* sysdeps/riscv/rvf/s_floorf.c: Likewise.
* sysdeps/sparc/sparc64/fpu/multiarch/s_floor.c: Likewise.
* sysdeps/sparc/sparc64/fpu/multiarch/s_floorf.c: Likewise.
* sysdeps/x86_64/fpu/multiarch/s_floor.c: Likewise.
* sysdeps/x86_64/fpu/multiarch/s_floorf.c: Likewise.
* sysdeps/powerpc/fpu/math_private.h [_ARCH_PWR5X] (__floor):
Remove macro.
[_ARCH_PWR5X] (__floorf): Likewise.
* sysdeps/x86_64/fpu/math_private.h [__SSE4_1__] (__floor): Remove
inline function.
[__SSE4_1__] (__floorf): Likewise.
* math/w_lgamma_main.c (LGFUNC (__lgamma)): Use floor functions
instead of __floor variants.
* math/w_lgamma_r_compat.c (__lgamma_r): Likewise.
* math/w_lgammaf_main.c (LGFUNC (__lgammaf)): Likewise.
* math/w_lgammaf_r_compat.c (__lgammaf_r): Likewise.
* math/w_lgammal_main.c (LGFUNC (__lgammal)): Likewise.
* math/w_lgammal_r_compat.c (__lgammal_r): Likewise.
* math/w_tgamma_compat.c (__tgamma): Likewise.
* math/w_tgamma_template.c (M_DECL_FUNC (__tgamma)): Likewise.
* math/w_tgammaf_compat.c (__tgammaf): Likewise.
* math/w_tgammal_compat.c (__tgammal): Likewise.
* sysdeps/ieee754/dbl-64/e_lgamma_r.c (sin_pi): Likewise.
* sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2):
Likewise.
* sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise.
* sysdeps/ieee754/flt-32/e_lgammaf_r.c (sin_pif): Likewise.
* sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise.
* sysdeps/ieee754/ldbl-128/e_lgammal_r.c (__ieee754_lgammal_r):
Likewise.
* sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Likewise.
* sysdeps/ieee754/ldbl-128/lgamma_negl.c (__lgamma_negl):
Likewise.
* sysdeps/ieee754/ldbl-128/s_expm1l.c (__expm1l): Likewise.
* sysdeps/ieee754/ldbl-128ibm/e_lgammal_r.c (__ieee754_lgammal_r):
Likewise.
* sysdeps/ieee754/ldbl-128ibm/e_powl.c (__ieee754_powl): Likewise.
* sysdeps/ieee754/ldbl-128ibm/lgamma_negl.c (__lgamma_negl):
Likewise.
* sysdeps/ieee754/ldbl-128ibm/s_expm1l.c (__expm1l): Likewise.
* sysdeps/ieee754/ldbl-128ibm/s_truncl.c (__truncl): Likewise.
* sysdeps/ieee754/ldbl-96/e_lgammal_r.c (sin_pi): Likewise.
* sysdeps/ieee754/ldbl-96/lgamma_negl.c (__lgamma_negl): Likewise.
* sysdeps/powerpc/power5+/fpu/s_modf.c (__modf): Likewise.
* sysdeps/powerpc/power5+/fpu/s_modff.c (__modff): Likewise.

51 files changed:
ChangeLog
include/math.h
math/w_lgamma_main.c
math/w_lgamma_r_compat.c
math/w_lgammaf_main.c
math/w_lgammaf_r_compat.c
math/w_lgammal_main.c
math/w_lgammal_r_compat.c
math/w_tgamma_compat.c
math/w_tgamma_template.c
math/w_tgammaf_compat.c
math/w_tgammal_compat.c
sysdeps/aarch64/fpu/s_floor.c
sysdeps/aarch64/fpu/s_floorf.c
sysdeps/ieee754/dbl-64/e_lgamma_r.c
sysdeps/ieee754/dbl-64/k_rem_pio2.c
sysdeps/ieee754/dbl-64/lgamma_neg.c
sysdeps/ieee754/dbl-64/s_floor.c
sysdeps/ieee754/dbl-64/wordsize-64/s_floor.c
sysdeps/ieee754/float128/s_floorf128.c
sysdeps/ieee754/flt-32/e_lgammaf_r.c
sysdeps/ieee754/flt-32/lgamma_negf.c
sysdeps/ieee754/flt-32/s_floorf.c
sysdeps/ieee754/ldbl-128/e_lgammal_r.c
sysdeps/ieee754/ldbl-128/e_powl.c
sysdeps/ieee754/ldbl-128/lgamma_negl.c
sysdeps/ieee754/ldbl-128/s_expm1l.c
sysdeps/ieee754/ldbl-128/s_floorl.c
sysdeps/ieee754/ldbl-128ibm/e_lgammal_r.c
sysdeps/ieee754/ldbl-128ibm/e_powl.c
sysdeps/ieee754/ldbl-128ibm/lgamma_negl.c
sysdeps/ieee754/ldbl-128ibm/s_expm1l.c
sysdeps/ieee754/ldbl-128ibm/s_floorl.c
sysdeps/ieee754/ldbl-128ibm/s_truncl.c
sysdeps/ieee754/ldbl-96/e_lgammal_r.c
sysdeps/ieee754/ldbl-96/lgamma_negl.c
sysdeps/m68k/m680x0/fpu/s_floor_template.c
sysdeps/powerpc/fpu/math_private.h
sysdeps/powerpc/power5+/fpu/s_modf.c
sysdeps/powerpc/power5+/fpu/s_modff.c
sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floor.c
sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floorf.c
sysdeps/powerpc/powerpc64/fpu/multiarch/s_floor.c
sysdeps/powerpc/powerpc64/fpu/multiarch/s_floorf.c
sysdeps/riscv/rv64/rvd/s_floor.c
sysdeps/riscv/rvf/s_floorf.c
sysdeps/sparc/sparc64/fpu/multiarch/s_floor.c
sysdeps/sparc/sparc64/fpu/multiarch/s_floorf.c
sysdeps/x86_64/fpu/math_private.h
sysdeps/x86_64/fpu/multiarch/s_floor.c
sysdeps/x86_64/fpu/multiarch/s_floorf.c

index 5bbf568a2761d88849ff45ed635859e9aaf1715a..b91461d01683cc20bd91f1b010aaa170130d6bcc 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,79 @@
+2018-09-14  Joseph Myers  <joseph@codesourcery.com>
+
+       * include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ &&
+       __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (MATH_REDIRECT):
+       New macro.
+       [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
+       && !NO_MATH_REDIRECT] (MATH_REDIRECT_LDBL): Likewise.
+       [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
+       && !NO_MATH_REDIRECT] (MATH_REDIRECT_F128): Likewise.
+       [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
+       && !NO_MATH_REDIRECT] (MATH_REDIRECT_UNARY_ARGS): Likewise.
+       [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
+       && !NO_MATH_REDIRECT] (sqrt): Redirect using MATH_REDIRECT.
+       [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
+       && !NO_MATH_REDIRECT] (floor): Likewise.
+       * sysdeps/aarch64/fpu/s_floor.c: Define NO_MATH_REDIRECT before
+       header inclusion.
+       * sysdeps/aarch64/fpu/s_floorf.c: Likewise.
+       * sysdeps/ieee754/dbl-64/s_floor.c: Likewise.
+       * sysdeps/ieee754/dbl-64/wordsize-64/s_floor.c: Likewise.
+       * sysdeps/ieee754/float128/s_floorf128.c: Likewise.
+       * sysdeps/ieee754/flt-32/s_floorf.c: Likewise.
+       * sysdeps/ieee754/ldbl-128/s_floorl.c: Likewise.
+       * sysdeps/ieee754/ldbl-128ibm/s_floorl.c: Likewise.
+       * sysdeps/m68k/m680x0/fpu/s_floor_template.c: Likewise.
+       * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floor.c: Likewise.
+       * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floorf.c: Likewise.
+       * sysdeps/powerpc/powerpc64/fpu/multiarch/s_floor.c: Likewise.
+       * sysdeps/powerpc/powerpc64/fpu/multiarch/s_floorf.c: Likewise.
+       * sysdeps/riscv/rv64/rvd/s_floor.c: Likewise.
+       * sysdeps/riscv/rvf/s_floorf.c: Likewise.
+       * sysdeps/sparc/sparc64/fpu/multiarch/s_floor.c: Likewise.
+       * sysdeps/sparc/sparc64/fpu/multiarch/s_floorf.c: Likewise.
+       * sysdeps/x86_64/fpu/multiarch/s_floor.c: Likewise.
+       * sysdeps/x86_64/fpu/multiarch/s_floorf.c: Likewise.
+       * sysdeps/powerpc/fpu/math_private.h [_ARCH_PWR5X] (__floor):
+       Remove macro.
+       [_ARCH_PWR5X] (__floorf): Likewise.
+       * sysdeps/x86_64/fpu/math_private.h [__SSE4_1__] (__floor): Remove
+       inline function.
+       [__SSE4_1__] (__floorf): Likewise.
+       * math/w_lgamma_main.c (LGFUNC (__lgamma)): Use floor functions
+       instead of __floor variants.
+       * math/w_lgamma_r_compat.c (__lgamma_r): Likewise.
+       * math/w_lgammaf_main.c (LGFUNC (__lgammaf)): Likewise.
+       * math/w_lgammaf_r_compat.c (__lgammaf_r): Likewise.
+       * math/w_lgammal_main.c (LGFUNC (__lgammal)): Likewise.
+       * math/w_lgammal_r_compat.c (__lgammal_r): Likewise.
+       * math/w_tgamma_compat.c (__tgamma): Likewise.
+       * math/w_tgamma_template.c (M_DECL_FUNC (__tgamma)): Likewise.
+       * math/w_tgammaf_compat.c (__tgammaf): Likewise.
+       * math/w_tgammal_compat.c (__tgammal): Likewise.
+       * sysdeps/ieee754/dbl-64/e_lgamma_r.c (sin_pi): Likewise.
+       * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2):
+       Likewise.
+       * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise.
+       * sysdeps/ieee754/flt-32/e_lgammaf_r.c (sin_pif): Likewise.
+       * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise.
+       * sysdeps/ieee754/ldbl-128/e_lgammal_r.c (__ieee754_lgammal_r):
+       Likewise.
+       * sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Likewise.
+       * sysdeps/ieee754/ldbl-128/lgamma_negl.c (__lgamma_negl):
+       Likewise.
+       * sysdeps/ieee754/ldbl-128/s_expm1l.c (__expm1l): Likewise.
+       * sysdeps/ieee754/ldbl-128ibm/e_lgammal_r.c (__ieee754_lgammal_r):
+       Likewise.
+       * sysdeps/ieee754/ldbl-128ibm/e_powl.c (__ieee754_powl): Likewise.
+       * sysdeps/ieee754/ldbl-128ibm/lgamma_negl.c (__lgamma_negl):
+       Likewise.
+       * sysdeps/ieee754/ldbl-128ibm/s_expm1l.c (__expm1l): Likewise.
+       * sysdeps/ieee754/ldbl-128ibm/s_truncl.c (__truncl): Likewise.
+       * sysdeps/ieee754/ldbl-96/e_lgammal_r.c (sin_pi): Likewise.
+       * sysdeps/ieee754/ldbl-96/lgamma_negl.c (__lgamma_negl): Likewise.
+       * sysdeps/powerpc/power5+/fpu/s_modf.c (__modf): Likewise.
+       * sysdeps/powerpc/power5+/fpu/s_modff.c (__modff): Likewise.
+
 2018-09-12  Joseph Myers  <joseph@codesourcery.com>
 
        * elf/Makefile (modules-names-tests): New variable.
index 9ab7aa440338f875213b5d9f1fe40e73ae2fbf83..eed953072b77e81762949200ae59a9ee7ba42696 100644 (file)
@@ -79,16 +79,29 @@ fabsf128 (_Float128 x)
 
 # if !(defined __FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0)
 #  ifndef NO_MATH_REDIRECT
-/* Declare sqrt for use within GLIBC.  Compilers typically inline sqrt as a
-   single instruction.  Use an asm to avoid use of PLTs if it doesn't.  */
-float (sqrtf) (float) asm ("__ieee754_sqrtf");
-double (sqrt) (double) asm ("__ieee754_sqrt");
-#   ifndef __NO_LONG_DOUBLE_MATH
-long double (sqrtl) (long double) asm ("__ieee754_sqrtl");
+/* Declare some functions for use within GLIBC.  Compilers typically
+   inline those functions as a single instruction.  Use an asm to
+   avoid use of PLTs if it doesn't.  */
+#   define MATH_REDIRECT(FUNC, PREFIX, ARGS)                   \
+  float (FUNC ## f) (ARGS (float)) asm (PREFIX #FUNC "f");     \
+  double (FUNC) (ARGS (double)) asm (PREFIX #FUNC );           \
+  MATH_REDIRECT_LDBL (FUNC, PREFIX, ARGS)                      \
+  MATH_REDIRECT_F128 (FUNC, PREFIX, ARGS)
+#   ifdef __NO_LONG_DOUBLE_MATH
+#    define MATH_REDIRECT_LDBL(FUNC, PREFIX, ARGS)
+#   else
+#    define MATH_REDIRECT_LDBL(FUNC, PREFIX, ARGS)                     \
+  long double (FUNC ## l) (ARGS (long double)) asm (PREFIX #FUNC "l");
 #   endif
-#   if __HAVE_DISTINCT_FLOAT128 > 0
-_Float128 (sqrtf128) (_Float128) asm ("__ieee754_sqrtf128");
+#   if __HAVE_DISTINCT_FLOAT128
+#    define MATH_REDIRECT_F128(FUNC, PREFIX, ARGS)                     \
+  _Float128 (FUNC ## f128) (ARGS (_Float128)) asm (PREFIX #FUNC "f128");
+#   else
+#    define MATH_REDIRECT_F128(FUNC, PREFIX, ARGS)
 #   endif
+#   define MATH_REDIRECT_UNARY_ARGS(TYPE) TYPE
+MATH_REDIRECT (sqrt, "__ieee754_", MATH_REDIRECT_UNARY_ARGS)
+MATH_REDIRECT (floor, "__", MATH_REDIRECT_UNARY_ARGS)
 #  endif
 # endif
 
index ac91b9d9e6ca5e9bc16e3ab2b2f65fca87237c1e..573bcb88fbc5d65ec09f3ee857b175d21c00ddb2 100644 (file)
@@ -31,7 +31,7 @@ LGFUNC (__lgamma) (double x)
        if(__builtin_expect(!isfinite(y), 0)
           && isfinite(x) && _LIB_VERSION != _IEEE_)
                return __kernel_standard(x, x,
-                                        __floor(x)==x&&x<=0.0
+                                        floor(x)==x&&x<=0.0
                                         ? 15 /* lgamma pole */
                                         : 14); /* lgamma overflow */
 
index 5b3ceaa2ea5a731749df09f5ec7afdfa6c419a1b..c68ce671746c1514011df0949ee3f9d29dac8d51 100644 (file)
@@ -28,7 +28,7 @@ __lgamma_r(double x, int *signgamp)
        if(__builtin_expect(!isfinite(y), 0)
           && isfinite(x) && _LIB_VERSION != _IEEE_)
                return __kernel_standard(x, x,
-                                        __floor(x)==x&&x<=0.0
+                                        floor(x)==x&&x<=0.0
                                         ? 15 /* lgamma pole */
                                         : 14); /* lgamma overflow */
 
index ef6065994f698b28445309478f1b02ec3f986ad2..2a85e3cadf293ab424ac1c1388bca2fabc2ad57d 100644 (file)
@@ -28,7 +28,7 @@ LGFUNC (__lgammaf) (float x)
        if(__builtin_expect(!isfinite(y), 0)
           && isfinite(x) && _LIB_VERSION != _IEEE_)
                return __kernel_standard_f(x, x,
-                                          __floorf(x)==x&&x<=0.0f
+                                          floorf(x)==x&&x<=0.0f
                                           ? 115 /* lgamma pole */
                                           : 114); /* lgamma overflow */
 
index c7751f13f58eecd2efa1dfa23bc202e80c9f792e..78fc4fcb239abd0a0c0acf8bf6c05103e7560bfa 100644 (file)
@@ -31,7 +31,7 @@ __lgammaf_r(float x, int *signgamp)
        if(__builtin_expect(!isfinite(y), 0)
           && isfinite(x) && _LIB_VERSION != _IEEE_)
                return __kernel_standard_f(x, x,
-                                          __floorf(x)==x&&x<=0.0f
+                                          floorf(x)==x&&x<=0.0f
                                           ? 115 /* lgamma pole */
                                           : 114); /* lgamma overflow */
 
index f269cef6ab56e3cb56ed8b3d2d3f4c96d3595415..04440cd29f101e05352b1a114939729082ad39f3 100644 (file)
@@ -35,7 +35,7 @@ LGFUNC (__lgammal) (long double x)
        if(__builtin_expect(!isfinite(y), 0)
           && isfinite(x) && _LIB_VERSION != _IEEE_)
                return __kernel_standard_l(x, x,
-                                          __floorl(x)==x&&x<=0.0L
+                                          floorl(x)==x&&x<=0.0L
                                           ? 215 /* lgamma pole */
                                           : 214); /* lgamma overflow */
 
index 09a8070b46942cbf58f34c8f5f100590d2accc29..6ebfa413334ff5bd4eba1b4386c6a9a0de4c0aa4 100644 (file)
@@ -32,7 +32,7 @@ __lgammal_r(long double x, int *signgamp)
        if(__builtin_expect(!isfinite(y), 0)
           && isfinite(x) && _LIB_VERSION != _IEEE_)
                return __kernel_standard(x, x,
-                                        __floorl(x)==x&&x<=0.0
+                                        floorl(x)==x&&x<=0.0
                                         ? 215 /* lgamma pole */
                                         : 214); /* lgamma overflow */
 
index 219aa108624bbc501bdfd42dd253b0c26b214cca..910d2fe4904e9b04952aba51e64cbed800cbb936 100644 (file)
@@ -33,7 +33,7 @@ __tgamma(double x)
           && _LIB_VERSION != _IEEE_) {
          if (x == 0.0)
            return __kernel_standard(x,x,50); /* tgamma pole */
-         else if(__floor(x)==x&&x<0.0)
+         else if(floor(x)==x&&x<0.0)
            return __kernel_standard(x,x,41); /* tgamma domain */
          else if (y == 0)
            __set_errno (ERANGE); /* tgamma underflow */
index 032f27a3f71c8f2955d62eefc9a59a08508b38c8..f570615d7b5c9313ccd72394e727c58de71eb782 100644 (file)
@@ -41,7 +41,7 @@ M_DECL_FUNC (__tgamma) (FLOAT x)
       if (x == 0)
        /* Pole error: tgamma(x=0).  */
        __set_errno (ERANGE);
-      else if (M_SUF (__floor) (x) == x && x < 0)
+      else if (M_SUF (floor) (x) == x && x < 0)
        /* Domain error: tgamma(integer x<0).  */
        __set_errno (EDOM);
       else
index e9ffddb7964cb35ff0870122474f6e96a7ab2a4b..ed509885aee2fcd46a4bdab9d2e7c53cca35ece5 100644 (file)
@@ -32,7 +32,7 @@ __tgammaf(float x)
          if (x == (float)0.0)
            /* tgammaf pole */
            return __kernel_standard_f(x, x, 150);
-         else if(__floorf(x)==x&&x<0.0f)
+         else if(floorf(x)==x&&x<0.0f)
            /* tgammaf domain */
            return __kernel_standard_f(x, x, 141);
          else if (y == 0)
index 3695b7fbb32f21b40df6fa81f9b30b925ca8fb4c..d79c788dfc183242bdff659e7f037189b647a9d1 100644 (file)
@@ -36,7 +36,7 @@ __tgammal(long double x)
           && _LIB_VERSION != _IEEE_) {
          if(x==0.0)
            return __kernel_standard_l(x,x,250); /* tgamma pole */
-         else if(__floorl(x)==x&&x<0.0L)
+         else if(floorl(x)==x&&x<0.0L)
            return __kernel_standard_l(x,x,241); /* tgamma domain */
          else if (y == 0)
            __set_errno (ERANGE); /* tgamma underflow */
index 725824689695a4bf8a0446ef5b261340b4d801b4..9580a5313d52ed0ce2abb0887245edd75c138733 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <libm-alias-double.h>
 
index bd197013adf593e3467ffe1562a63a3fc4d8c4d2..a874aaedafe23def2549519799345c05e76babc0 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <libm-alias-float.h>
 
index 17717d915f0cf7e6dfb274174f37009e2254f95e..88051bc75bc44cd23e3efabf7ad17dbb17264816 100644 (file)
@@ -168,10 +168,10 @@ sin_pi(double x)
      * argument reduction, make sure inexact flag not raised if input
      * is an integer
      */
-       z = __floor(y);
+       z = floor(y);
        if(z!=y) {                              /* inexact anyway */
            y  *= 0.5;
-           y   = 2.0*(y - __floor(y));         /* y = |x| mod 2.0 */
+           y   = 2.0*(y - floor(y));           /* y = |x| mod 2.0 */
            n   = (int) (y*4.0);
        } else {
            if(ix>=0x43400000) {
index d8403dc34502c4e17b9c2f3fe41d22b3581ac237..6221a1a474f5dadb8a7bd3d5bf64f58474b02d9e 100644 (file)
@@ -196,7 +196,7 @@ recompute:
 
   /* compute n */
   z = __scalbn (z, q0);                 /* actual value of z */
-  z -= 8.0 * __floor (z * 0.125);               /* trim off integer >= 8 */
+  z -= 8.0 * floor (z * 0.125);               /* trim off integer >= 8 */
   n = (int32_t) z;
   z -= (double) n;
   ih = 0;
index eaa6f641ebab6d04c7027d1b97514758b148fccb..56a3fca1baf7a4273ef0c46096d0858f5cc5602b 100644 (file)
@@ -282,7 +282,7 @@ __lgamma_neg (double x, int *signgamp)
 {
   /* Determine the half-integer region X lies in, handle exact
      integers and determine the sign of the result.  */
-  int i = __floor (-2 * x);
+  int i = floor (-2 * x);
   if ((i & 1) == 0 && i == -2 * x)
     return 1.0 / 0.0;
   double xn = ((i & 1) == 0 ? -i / 2 : (-i - 1) / 2);
@@ -299,7 +299,7 @@ __lgamma_neg (double x, int *signgamp)
      approximations to an adjusted version of the gamma function.  */
   if (i < 2)
     {
-      int j = __floor (-8 * x) - 16;
+      int j = floor (-8 * x) - 16;
       double xm = (-33 - 2 * j) * 0.0625;
       double x_adj = x - xm;
       size_t deg = poly_deg[j];
index f27c6f3ad21ac73b1bf1bd285d401ea95975b940..bebc01865890e5bb999d7de593405cea3c9811fa 100644 (file)
@@ -17,6 +17,7 @@
  *     Bit twiddling.
  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <libm-alias-double.h>
index f7e0a77ec3612001cd296ee7f1e29b772879fb88..44c1e197549a22220db8e836a49461f07ca39708 100644 (file)
@@ -30,6 +30,7 @@
  * ====================================================
  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <stdint.h>
index 18298436a1a4e163deb3b2bbaf0595f46671bf90..e0a6412980374641e65779755d995155623191da 100644 (file)
@@ -1,2 +1,3 @@
+#define NO_MATH_REDIRECT
 #include <float128_private.h>
 #include "../ldbl-128/s_floorl.c"
index ebe2d3462fe0c356db8474a1d3d9c0ef9170656a..a7f9b9fbadc49c353b5e65851a432966ed2b0ab1 100644 (file)
@@ -104,10 +104,10 @@ sin_pif(float x)
      * argument reduction, make sure inexact flag not raised if input
      * is an integer
      */
-       z = __floorf(y);
+       z = floorf(y);
        if(z!=y) {                              /* inexact anyway */
            y  *= (float)0.5;
-           y   = (float)2.0*(y - __floorf(y)); /* y = |x| mod 2.0 */
+           y   = (float)2.0*(y - floorf(y));   /* y = |x| mod 2.0 */
            n   = (int) (y*(float)4.0);
        } else {
            if(ix>=0x4b800000) {
index 7951cde5c78249f699c28cec699a22103d59d706..c20b816acc5ebef196746e4a836c8cd2536ea23f 100644 (file)
@@ -197,7 +197,7 @@ __lgamma_negf (float x, int *signgamp)
 {
   /* Determine the half-integer region X lies in, handle exact
      integers and determine the sign of the result.  */
-  int i = __floorf (-2 * x);
+  int i = floorf (-2 * x);
   if ((i & 1) == 0 && i == -2 * x)
     return 1.0f / 0.0f;
   float xn = ((i & 1) == 0 ? -i / 2 : (-i - 1) / 2);
@@ -214,7 +214,7 @@ __lgamma_negf (float x, int *signgamp)
      approximations to an adjusted version of the gamma function.  */
   if (i < 2)
     {
-      int j = __floorf (-8 * x) - 16;
+      int j = floorf (-8 * x) - 16;
       float xm = (-33 - 2 * j) * 0.0625f;
       float x_adj = x - xm;
       size_t deg = poly_deg[j];
index 12aed343a0e7b334017c7c3d72046e77fee89e79..b34d967f01367877171c8c14baf5f508366ac7a5 100644 (file)
@@ -20,6 +20,7 @@
  *     Bit twiddling.
  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <libm-alias-float.h>
index 5c50e4616a94e1aeedb653043d799e9133e8a90f..f470034f9c6b91a6e444d08094750c0ad092024d 100644 (file)
@@ -776,11 +776,11 @@ __ieee754_lgammal_r (_Float128 x, int *signgamp)
       if (x < -2 && x > -50)
        return __lgamma_negl (x, signgamp);
       q = -x;
-      p = __floorl (q);
+      p = floorl (q);
       if (p == q)
        return (one / fabsl (p - p));
       _Float128 halfp = p * L(0.5);
-      if (halfp == __floorl (halfp))
+      if (halfp == floorl (halfp))
        *signgamp = -1;
       else
        *signgamp = 1;
@@ -801,7 +801,7 @@ __ieee754_lgammal_r (_Float128 x, int *signgamp)
   if (x < L(13.5))
     {
       p = 0;
-      nx = __floorl (x + L(0.5));
+      nx = floorl (x + L(0.5));
       nn = nx;
       switch (nn)
        {
index dc748c3a0b5af0e1a9bcfb5166c4cc83d80f9566..47226f8688477491f4bd985718a2a44eb34cd0eb 100644 (file)
@@ -198,10 +198,10 @@ __ieee754_powl (_Float128 x, _Float128 y)
        yisint = 2;             /* even integer y */
       else if (iy >= 0x3fff0000)       /* 1.0 */
        {
-         if (__floorl (y) == y)
+         if (floorl (y) == y)
            {
              z = 0.5 * y;
-             if (__floorl (z) == z)
+             if (floorl (z) == z)
                yisint = 2;
              else
                yisint = 1;
@@ -413,7 +413,7 @@ __ieee754_powl (_Float128 x, _Float128 y)
   n = 0;
   if (i > 0x3ffe0000)
     {                          /* if |z| > 0.5, set n = [z+0.5] */
-      n = __floorl (z + L(0.5));
+      n = floorl (z + L(0.5));
       t = n;
       p_h -= t;
     }
index cb64d4b0a9895df230c82ac8c2f0eca55af3a945..c0bf1661dceffa4de8c77733f5377a8e5a05ca9d 100644 (file)
@@ -449,7 +449,7 @@ __lgamma_negl (_Float128 x, int *signgamp)
 {
   /* Determine the half-integer region X lies in, handle exact
      integers and determine the sign of the result.  */
-  int i = __floorl (-2 * x);
+  int i = floorl (-2 * x);
   if ((i & 1) == 0 && i == -2 * x)
     return L(1.0) / L(0.0);
   _Float128 xn = ((i & 1) == 0 ? -i / 2 : (-i - 1) / 2);
@@ -466,7 +466,7 @@ __lgamma_negl (_Float128 x, int *signgamp)
      approximations to an adjusted version of the gamma function.  */
   if (i < 2)
     {
-      int j = __floorl (-8 * x) - 16;
+      int j = floorl (-8 * x) - 16;
       _Float128 xm = (-33 - 2 * j) * L(0.0625);
       _Float128 x_adj = x - xm;
       size_t deg = poly_deg[j];
index 66881af01a5691ec194878ced3bd75066ea84cef..08f9ec848b1aec64398d2254fd6247a19dfd6844 100644 (file)
@@ -136,7 +136,7 @@ __expm1l (_Float128 x)
 
   /* Express x = ln 2 (k + remainder), remainder not exceeding 1/2. */
   xx = C1 + C2;                        /* ln 2. */
-  px = __floorl (0.5 + x / xx);
+  px = floorl (0.5 + x / xx);
   k = px;
   /* remainder times ln 2 */
   x -= px * C1;
index f9c5e014f9a0913f3e994d01f93b51f176216de4..f340a3fbcad9647a8f1f4519a88197bd6f313ade 100644 (file)
@@ -24,6 +24,7 @@ static char rcsid[] = "$NetBSD: $";
  *     Bit twiddling.
  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <libm-alias-ldouble.h>
index 5b628bedc18075e241695c541af74722917fa9dc..ae2e6559b02149f823dc37265c014356ca435b1b 100644 (file)
@@ -726,11 +726,11 @@ __ieee754_lgammal_r (long double x, int *signgamp)
       if (x < -2 && x > -48)
        return __lgamma_negl (x, signgamp);
       q = -x;
-      p = __floorl (q);
+      p = floorl (q);
       if (p == q)
        return (one / fabsl (p - p));
       long double halfp = p * 0.5L;
-      if (halfp == __floorl (halfp))
+      if (halfp == floorl (halfp))
        *signgamp = -1;
       else
        *signgamp = 1;
@@ -751,7 +751,7 @@ __ieee754_lgammal_r (long double x, int *signgamp)
   if (x < 13.5L)
     {
       p = 0;
-      nx = __floorl (x + 0.5L);
+      nx = floorl (x + 0.5L);
       nn = nx;
       switch (nn)
        {
index f59ad4e113b55ee2a8021c636e2534e68d0c6acc..1f0f2b4c0418971e2e04e13aa7932ac5a3bdb196 100644 (file)
@@ -195,10 +195,10 @@ __ieee754_powl (long double x, long double y)
        yisint = 2;             /* even integer y */
       else if (iy >= 0x3ff00000)       /* 1.0 */
        {
-         if (__floorl (y) == y)
+         if (floorl (y) == y)
            {
              z = 0.5 * y;
-             if (__floorl (z) == z)
+             if (floorl (z) == z)
                yisint = 2;
              else
                yisint = 1;
@@ -392,7 +392,7 @@ __ieee754_powl (long double x, long double y)
   n = 0;
   if (i > 0x3fe00000)
     {                          /* if |z| > 0.5, set n = [z+0.5] */
-      n = __floorl (z + 0.5L);
+      n = floorl (z + 0.5L);
       t = n;
       p_h -= t;
     }
index c96b641e0257a670ec1f5ddcb406dd457fa5fc36..c35965726905570a73d0c089164fe17570dab868 100644 (file)
@@ -430,7 +430,7 @@ __lgamma_negl (long double x, int *signgamp)
 {
   /* Determine the half-integer region X lies in, handle exact
      integers and determine the sign of the result.  */
-  int i = __floorl (-2 * x);
+  int i = floorl (-2 * x);
   if ((i & 1) == 0 && i == -2 * x)
     return 1.0L / 0.0L;
   long double xn = ((i & 1) == 0 ? -i / 2 : (-i - 1) / 2);
@@ -447,7 +447,7 @@ __lgamma_negl (long double x, int *signgamp)
      approximations to an adjusted version of the gamma function.  */
   if (i < 2)
     {
-      int j = __floorl (-8 * x) - 16;
+      int j = floorl (-8 * x) - 16;
       long double xm = (-33 - 2 * j) * 0.0625L;
       long double x_adj = x - xm;
       size_t deg = poly_deg[j];
index 42d57c6eec2670214d2a60aaab1ab0349912846a..22abee4d9985320bfd3219a0139de26f71322f84 100644 (file)
@@ -120,7 +120,7 @@ __expm1l (long double x)
 
   /* Express x = ln 2 (k + remainder), remainder not exceeding 1/2. */
   xx = C1 + C2;                        /* ln 2. */
-  px = __floorl (0.5 + x / xx);
+  px = floorl (0.5 + x / xx);
   k = px;
   /* remainder times ln 2 */
   x -= px * C1;
index 4aae5ae6082b25f3e00110ce951e2b7d15f7bfca..f33b6ad701d3cca5ad315ffc5a35c3ca11dd4b2b 100644 (file)
@@ -17,6 +17,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <math_ldbl_opt.h>
index a915a01ac6c3d184da0fea89b3541181e179bf48..a366c42599e82a2cfb53a087cd19c86e042948bb 100644 (file)
@@ -47,7 +47,7 @@ __truncl (long double x)
       else
        {
          /* The high part is a nonzero integer.  */
-         lo = xh > 0 ? __floor (xl) : __ceil (xl);
+         lo = xh > 0 ? floor (xl) : __ceil (xl);
          xh = hi;
          xl = lo;
          ldbl_canonicalize_int (&xh, &xl);
index 200421f5cceee3a2f6df00a434606f17110c93c6..a5d6d0dea5e5d86be675ce163cd5a7328082ed64 100644 (file)
@@ -221,11 +221,11 @@ sin_pi (long double x)
    * argument reduction, make sure inexact flag not raised if input
    * is an integer
    */
-  z = __floorl (y);
+  z = floorl (y);
   if (z != y)
     {                          /* inexact anyway */
       y  *= 0.5;
-      y = 2.0*(y - __floorl(y));               /* y = |x| mod 2.0 */
+      y = 2.0*(y - floorl(y));         /* y = |x| mod 2.0 */
       n = (int) (y*4.0);
     }
   else
index 90bb8345a0e92c7d376a89a0e9b7abcea821c864..eaa41d6b3a7f956435e7541ad7f857927acd66eb 100644 (file)
@@ -316,7 +316,7 @@ __lgamma_negl (long double x, int *signgamp)
 {
   /* Determine the half-integer region X lies in, handle exact
      integers and determine the sign of the result.  */
-  int i = __floorl (-2 * x);
+  int i = floorl (-2 * x);
   if ((i & 1) == 0 && i == -2 * x)
     return 1.0L / 0.0L;
   long double xn = ((i & 1) == 0 ? -i / 2 : (-i - 1) / 2);
@@ -333,7 +333,7 @@ __lgamma_negl (long double x, int *signgamp)
      approximations to an adjusted version of the gamma function.  */
   if (i < 2)
     {
-      int j = __floorl (-8 * x) - 16;
+      int j = floorl (-8 * x) - 16;
       long double xm = (-33 - 2 * j) * 0.0625L;
       long double x_adj = x - xm;
       size_t deg = poly_deg[j];
index 7779813d84b09be0ad6dc7bc41b1b0ca35733452..1bead5aa3e5bdaaae570f93e637a1916ade12f11 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library.  If not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 
 FLOAT
index 36fcb3c654c685a2090624403c7df79d9d81d0ca..dc6dbfa474c97b97012000a9a9693ff4e57e6a0e 100644 (file)
@@ -97,26 +97,6 @@ __ieee754_sqrtf128 (_Float128 __x)
      __z; })
 # endif
 
-# ifndef __floor
-#  define __floor(x)                   \
-    ({ double __z;                     \
-     __asm __volatile (                        \
-       "       frim %0,%1\n"           \
-               : "=f" (__z)            \
-               : "f" (x));             \
-     __z; })
-# endif
-# ifndef __floorf
-#  define __floorf(x)                  \
-    ({ float __z;                      \
-     __asm __volatile (                        \
-       "       frim %0,%1\n"           \
-       "       frsp %0,%0\n"           \
-               : "=f" (__z)            \
-               : "f" (x));             \
-     __z; })
-# endif
-
 #endif /* defined _ARCH_PWR5X */
 
 #endif /* _PPC_MATH_PRIVATE_H_ */
index 7a32d313032ffe73f294c17007760a6542a73531..3d3b3e7866dc8fec61956bd7198d9ea884f41191 100644 (file)
@@ -36,7 +36,7 @@ __modf (double x, double *iptr)
 
   if (x >= 0.0)
     {
-      *iptr = __floor (x);
+      *iptr = floor (x);
       return __copysign (x - *iptr, x);
     }
   else
index c1bbae64799067bccdddbf4c164302df91b92dff..de44218982835a252c1d0e369c3099985e699b86 100644 (file)
@@ -35,7 +35,7 @@ __modff (float x, float *iptr)
 
   if (x >= 0.0)
     {
-      *iptr = __floorf (x);
+      *iptr = floorf (x);
       return __copysignf (x - *iptr, x);
     }
   else
index 0152ea606e1e9ec7af998829de54de03fbfc1ce2..5380471af7738b3e62ce4f93406c5b5dad5fe8f8 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_ldbl_opt.h>
 #include <shlib-compat.h>
index 57ae50c9f6df9004f3f5402d0a6595c1a3547c14..cd95393e82b13a375e4c1e244d3f50cb8f265203 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_ldbl_opt.h>
 #include <shlib-compat.h>
index d1a21a1d12a567bd65f7b1cddc7b93dac0a2c52b..3b21afc91171dcd31809b17181bdcfa801467015 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_ldbl_opt.h>
 #include <shlib-compat.h>
index d1bbc1461434ea8a5236e3c27bf761960a6b9ea2..7b89aececca0404ca44a47947cbf61ae938e6887 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_ldbl_opt.h>
 #include <shlib-compat.h>
index da3b11cdb46e73c9dbe93b8f0896216cba431db2..84a609fd19f5463db75bc74afbaa1eafa6f26cef 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library.  If not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <fenv_private.h>
index 560553ffbaecbb13b5ff777c485a76e54f8e8836..ba91d37914c7bea50e58bb5553b9fec735166b78 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library.  If not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <math.h>
 #include <math_private.h>
 #include <fenv_private.h>
index 6e5ecd2b5d9734716d86eef39994e43d47aa5cfe..910e7c1486ee54658c564d0e20b4371260695512 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <sparc-ifunc.h>
 #include <math.h>
 #include <libm-alias-double.h>
index b79fd83fa428ef2e5655588110055b21dfc3bb08..788d69cd9633bdf0cec8d37e4c531eb429e5729c 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <sparc-ifunc.h>
 #include <math.h>
 #include <libm-alias-float.h>
index 306875f92b307683dacae4814ba3102248361d11..e5bf46f6b1ac0ce2769e1af54acfde83ea1c7bd3 100644 (file)
@@ -27,30 +27,6 @@ __rintf (float d)
 # endif
   return res;
 }
-
-extern __always_inline double
-__floor (double d)
-{
-  double res;
-# if defined __AVX__ || defined SSE2AVX
-  asm ("vroundsd $1, %1, %0, %0" : "=x" (res) : "xm" (d));
-# else
-  asm ("roundsd $1, %1, %0" : "=x" (res) : "xm" (d));
-# endif
-  return res;
-}
-
-extern __always_inline float
-__floorf (float d)
-{
-  float res;
-# if defined __AVX__ || defined SSE2AVX
-  asm ("vroundss $1, %1, %0, %0" : "=x" (res) : "xm" (d));
-# else
-  asm ("roundss $1, %1, %0" : "=x" (res) : "xm" (d));
-#  endif
-  return res;
-}
 #endif /* __SSE4_1__ */
 
 #endif /* X86_64_MATH_PRIVATE_H */
index 58f8ed8eaf12d8f0444c17c518039dc14f0923d4..2171863609a3a92ebc0ae36e7b18f730f272d426 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <libm-alias-double.h>
 
 #define floor __redirect_floor
index 5ef2fec2e395f878e7bdab720d2bcbd8a8f88cf9..82987974debc8479bd124db5e5c9a5ef52227c70 100644 (file)
@@ -16,6 +16,7 @@
    License along with the GNU C Library; if not, see
    <http://www.gnu.org/licenses/>.  */
 
+#define NO_MATH_REDIRECT
 #include <libm-alias-float.h>
 
 #define floorf __redirect_floorf