Use libm_alias_double for dbl-64 modf

System Internals / glibc - Joseph Myers [] - 3 October 2017 19:46 EDT

This patch makes dbl-64 modf use libm_alias_double. Both the dbl-64 and dbl-64/wordsize-64 versions are changed, and the ldbl-opt version is changed to define the libc compat symbol only. Because of multiarch wrappers, the changed implementations are made not to define aliases at all if __modf is defined as a macro, as with other functions, so avoiding duplicate compat symbols while allowing those wrappers to be simplified.

Tested for x86_64, and verified with that installed stripped shared libraries are unchanged by the patch.

- sysdeps/ieee754/dbl-64/s_modf.c: Include . (modf): Define using libm_alias_double, only if [!__modf].
- sysdeps/ieee754/dbl-64/wordsize-64/s_modf.c: Include . (modf): Define using libm_alias_double, only if [!__modf].
- sysdeps/ieee754/ldbl-opt/s_modf.c (modfl): Only define libc compat symbol here.
- sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_modf-ppc32.c (weak_alias): Do not undefine and redefine. (strong_alias): Likewise.
- sysdeps/powerpc/powerpc64/fpu/multiarch/s_modf-ppc64.c (weak_alias): Likewise. (strong_alias): Likewise.

d8f619b Use libm_alias_double for dbl-64 modf.
ChangeLog | 14 ++++++++++++++
sysdeps/ieee754/dbl-64/s_modf.c | 7 +++----
sysdeps/ieee754/dbl-64/wordsize-64/s_modf.c | 7 +++----
sysdeps/ieee754/ldbl-opt/s_modf.c | 6 +-----
.../powerpc/powerpc32/power4/fpu/multiarch/s_modf-ppc32.c | 5 -----
sysdeps/powerpc/powerpc64/fpu/multiarch/s_modf-ppc64.c | 5 -----
6 files changed, 21 insertions(+), 23 deletions(-)


  • Share