diff options
author | Richard Henderson <rth@twiddle.net> | 2013-06-24 09:59:26 -0700 |
---|---|---|
committer | Richard Henderson <rth@twiddle.net> | 2013-06-24 18:12:24 -0700 |
commit | 385fd0d524817f171c715c1ca0e5647741584682 (patch) | |
tree | a6ebec5461c8aec9d0178dc8d48f2cf9edcb9d11 /ports/sysdeps/alpha/fpu/e_sqrt.c | |
parent | 17db6e8d6b12f55e312fcab46faf5d332c806fb6 (diff) | |
download | glibc-385fd0d524817f171c715c1ca0e5647741584682.tar glibc-385fd0d524817f171c715c1ca0e5647741584682.tar.gz glibc-385fd0d524817f171c715c1ca0e5647741584682.tar.bz2 glibc-385fd0d524817f171c715c1ca0e5647741584682.zip |
[BZ #15666] alpha: Add __sqrt*_finite definitions
With compatibility for ev6 and non-ev6 builds, as the non-ev6 did
manage to get definitions emitted for the float and double functions.
Diffstat (limited to 'ports/sysdeps/alpha/fpu/e_sqrt.c')
-rw-r--r-- | ports/sysdeps/alpha/fpu/e_sqrt.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/ports/sysdeps/alpha/fpu/e_sqrt.c b/ports/sysdeps/alpha/fpu/e_sqrt.c index 538ff1da62..6abca0896e 100644 --- a/ports/sysdeps/alpha/fpu/e_sqrt.c +++ b/ports/sysdeps/alpha/fpu/e_sqrt.c @@ -18,6 +18,7 @@ #include <math.h> #include <math_private.h> +#include <shlib-compat.h> #if !defined(_IEEE_FP_INEXACT) @@ -157,9 +158,30 @@ $fixup: \n\ \n\ .end __ieee754_sqrt"); +/* Avoid the __sqrt_finite alias that dbl-64/e_sqrt.c would give... */ +#undef strong_alias +#define strong_alias(a,b) + +/* ... defining our own. */ +#if SHLIB_COMPAT (libm, GLIBC_2_15, GLIBC_2_18) +asm (".global __sqrt_finite1; __sqrt_finite1 = __ieee754_sqrt"); +#else +asm (".global __sqrt_finite; __sqrt_finite = __ieee754_sqrt"); +#endif + static double __full_ieee754_sqrt(double) __attribute_used__; #define __ieee754_sqrt __full_ieee754_sqrt +#elif SHLIB_COMPAT (libm, GLIBC_2_15, GLIBC_2_18) +# define __sqrt_finite __sqrt_finite1 #endif /* _IEEE_FP_INEXACT */ #include <sysdeps/ieee754/dbl-64/e_sqrt.c> + +/* Work around forgotten symbol in alphaev6 build. */ +#if SHLIB_COMPAT (libm, GLIBC_2_15, GLIBC_2_18) +# undef __sqrt_finite +# undef __ieee754_sqrt +compat_symbol (libm, __sqrt_finite1, __sqrt_finite, GLIBC_2_15); +versioned_symbol (libm, __ieee754_sqrt, __sqrt_finite, GLIBC_2_18); +#endif |