This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] PowerPC: fix libm ABI issue for llroundl


While testing the modf optimization I noted an ABI issue for
some PPC32 builds configuration:

--- ../sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/nptl/libm.abilist  2013-03-22 14:03:05.181899402 -0500
+++ /home/azanella/glibc/build/glibc32_powerpc/math/libm.symlist        2013-03-25 11:59:29.250240003 -0500
@@ -277 +276,0 @@ GLIBC_2.1
- llroundl F

This patch fixes it. Tested on PPC32 (powerpc, POWER4 and POWER7 builds)
Any tips, advices, comments?

---

2013-03-25  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>

	* sysdeps/powerpc/fpu/s_llround.c: Fix libm ABI issue with missing
	llroundl symbol when building for PPC32.

--

diff --git a/sysdeps/powerpc/fpu/s_llround.c b/sysdeps/powerpc/fpu/s_llround.c
index b53d6ee..c16d25e 100644
--- a/sysdeps/powerpc/fpu/s_llround.c
+++ b/sysdeps/powerpc/fpu/s_llround.c
@@ -17,6 +17,7 @@
    <http://www.gnu.org/licenses/>.  */
 
 #include <math.h>
+#include <math_ldbl_opt.h>
 
 /* I think that what this routine is supposed to do is round a value
    to the nearest integer, with values exactly on the boundary rounded
@@ -47,3 +48,6 @@ weak_alias (__llround, llround)
 strong_alias (__llround, __llroundl)
 weak_alias (__llround, llroundl)
 #endif
+#if LONG_DOUBLE_COMPAT(libm, GLIBC_2_1)
+compat_symbol (libm, __llround, llroundl, GLIBC_2_1);
+#endif
-- 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]