]> sourceware.org Git - glibc.git/commitdiff
Fix powerpc64le problem from last ldbl-opt patch.
authorJoseph Myers <joseph@codesourcery.com>
Mon, 18 Sep 2017 23:26:35 +0000 (23:26 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Mon, 18 Sep 2017 23:26:35 +0000 (23:26 +0000)
This patch fixes a problem on powerpc64le that I missed in initial
testing of my last patch to ldbl-opt.  In the specific case of
powerpc64le, the weak aliases for exp10l and remainderl do not get
defined in the generic wrappers because of how those wrappers
undefine and redefine weak_alias.  This patch restores those aliases
in the ldbl-opt code.

Tested (compilation only) for powerpc64le with build-many-glibcs.py.

* sysdeps/ieee754/ldbl-opt/w_exp10l_compat.c [LIBM_SVID_COMPAT &&
!LONG_DOUBLE_COMPAT (libm, GLIBC_2_1)] (weak_alias): Undefine and
redefine.
[LIBM_SVID_COMPAT && !LONG_DOUBLE_COMPAT (libm, GLIBC_2_1)]
(exp10l): Define as weak alias.
* sysdeps/ieee754/ldbl-opt/w_remainderl_compat.c [LIBM_SVID_COMPAT
&& !LONG_DOUBLE_COMPAT (libm, GLIBC_2_0)] (weak_alias): Undefine
and redefine.
[LIBM_SVID_COMPAT && !LONG_DOUBLE_COMPAT (libm, GLIBC_2_0)]
(remainderl): Define as weak alias.

ChangeLog
sysdeps/ieee754/ldbl-opt/w_exp10l_compat.c
sysdeps/ieee754/ldbl-opt/w_remainderl_compat.c

index a7bcaa689b3659c5b4616c6a0e02a352e3c1bfce..757462f14eb1ed702042eb97b2fb28b91d41b4c0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,16 @@
 2017-09-18  Joseph Myers  <joseph@codesourcery.com>
 
+       * sysdeps/ieee754/ldbl-opt/w_exp10l_compat.c [LIBM_SVID_COMPAT &&
+       !LONG_DOUBLE_COMPAT (libm, GLIBC_2_1)] (weak_alias): Undefine and
+       redefine.
+       [LIBM_SVID_COMPAT && !LONG_DOUBLE_COMPAT (libm, GLIBC_2_1)]
+       (exp10l): Define as weak alias.
+       * sysdeps/ieee754/ldbl-opt/w_remainderl_compat.c [LIBM_SVID_COMPAT
+       && !LONG_DOUBLE_COMPAT (libm, GLIBC_2_0)] (weak_alias): Undefine
+       and redefine.
+       [LIBM_SVID_COMPAT && !LONG_DOUBLE_COMPAT (libm, GLIBC_2_0)]
+       (remainderl): Define as weak alias.
+
        * math/s_fmal.c: Include <libm-alias-ldouble.h>.
        (fmal): Define using libm_alias_ldouble.
        * math/w_acoshl_compat.c: Include <libm-alias-ldouble.h>.
index 1c0e8754dd1f0a961cd75de0dbbd11a699b4d308..dd5915e66e2587b9faf1cceb73fe3939796befd8 100644 (file)
@@ -5,6 +5,14 @@
 #define compat_symbol(l,n,a,v)
 #include <math/w_exp10l_compat.c>
 #if LIBM_SVID_COMPAT
+# if !LONG_DOUBLE_COMPAT (libm, GLIBC_2_1)
+/* If ldbl-opt is used without special versioning for exp10l being
+   required, the generic code does not define exp10l because of the
+   undefine and redefine of weak_alias above.  */
+#  undef weak_alias
+#  define weak_alias(name, aliasname) _weak_alias (name, aliasname)
+weak_alias (__exp10l, exp10l)
+# endif
 # if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_27)
 /* compat_symbol was undefined and redefined above to avoid the
    default pow10l compat symbol at version GLIBC_2_1 (as for ldbl-opt
index 9314117edaf8f0cec339d00e72c0fe1e32a38c56..bb9bac0db7ee4c39cc9ac173317413eda365d875 100644 (file)
@@ -3,6 +3,14 @@
 #define weak_alias(n,a)
 #include <math/w_remainderl_compat.c>
 #if LIBM_SVID_COMPAT
+# if !LONG_DOUBLE_COMPAT (libm, GLIBC_2_0)
+/* If ldbl-opt is used without special versioning for remainderl being
+   required, the generic code does not define remainderl because of
+   the undefine and redefine of weak_alias above.  */
+#  undef weak_alias
+#  define weak_alias(name, aliasname) _weak_alias (name, aliasname)
+weak_alias (__remainderl, remainderl)
+# endif
 strong_alias (__remainderl, __dreml)
 long_double_symbol (libm, __dreml, dreml);
 #endif
This page took 0.083118 seconds and 5 git commands to generate.