From 76a66d510a3737674563133a420f4fd22da42c1b Mon Sep 17 00:00:00 2001 From: Anton Blanchard Date: Sat, 17 Aug 2013 18:33:02 +0930 Subject: [PATCH] PowerPC floating point little-endian [14 of 15] http://sourceware.org/ml/libc-alpha/2013-07/msg00205.html These all wrongly specified float constants in a 64-bit word. * sysdeps/powerpc/powerpc64/fpu/s_ceilf.S: Correct float constants for little-endian. * sysdeps/powerpc/powerpc64/fpu/s_floorf.S: Likewise. * sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S: Likewise. * sysdeps/powerpc/powerpc64/fpu/s_rintf.S: Likewise. * sysdeps/powerpc/powerpc64/fpu/s_roundf.S: Likewise. * sysdeps/powerpc/powerpc64/fpu/s_truncf.S: Likewise. --- ChangeLog | 10 ++++++++++ sysdeps/powerpc/powerpc64/fpu/s_ceilf.S | 4 +++- sysdeps/powerpc/powerpc64/fpu/s_floorf.S | 4 +++- sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S | 4 +++- sysdeps/powerpc/powerpc64/fpu/s_rintf.S | 4 +++- sysdeps/powerpc/powerpc64/fpu/s_roundf.S | 6 ++++-- sysdeps/powerpc/powerpc64/fpu/s_truncf.S | 4 +++- 7 files changed, 29 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 45b4f7664b..f84a9e4acd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2013-10-04 Anton Blanchard + + * sysdeps/powerpc/powerpc64/fpu/s_ceilf.S: Correct float constants + for little-endian. + * sysdeps/powerpc/powerpc64/fpu/s_floorf.S: Likewise. + * sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S: Likewise. + * sysdeps/powerpc/powerpc64/fpu/s_rintf.S: Likewise. + * sysdeps/powerpc/powerpc64/fpu/s_roundf.S: Likewise. + * sysdeps/powerpc/powerpc64/fpu/s_truncf.S: Likewise. + 2013-10-04 Alan Modra * sysdeps/powerpc/powerpc32/fpu/s_roundf.S: Increase alignment of diff --git a/sysdeps/powerpc/powerpc64/fpu/s_ceilf.S b/sysdeps/powerpc/powerpc64/fpu/s_ceilf.S index 801af5d0aa..45f71d7ac5 100644 --- a/sysdeps/powerpc/powerpc64/fpu/s_ceilf.S +++ b/sysdeps/powerpc/powerpc64/fpu/s_ceilf.S @@ -19,8 +19,10 @@ #include .section ".toc","aw" + .p2align 3 .LC0: /* 2**23 */ - .tc FD_4b000000_0[TC],0x4b00000000000000 + .long 0x4b000000 + .long 0x0 .section ".text" EALIGN (__ceilf, 4, 0) diff --git a/sysdeps/powerpc/powerpc64/fpu/s_floorf.S b/sysdeps/powerpc/powerpc64/fpu/s_floorf.S index a0a22e7eb9..e85b820b21 100644 --- a/sysdeps/powerpc/powerpc64/fpu/s_floorf.S +++ b/sysdeps/powerpc/powerpc64/fpu/s_floorf.S @@ -19,8 +19,10 @@ #include .section ".toc","aw" + .p2align 3 .LC0: /* 2**23 */ - .tc FD_4b000000_0[TC],0x4b00000000000000 + .long 0x4b000000 + .long 0x0 .section ".text" EALIGN (__floorf, 4, 0) diff --git a/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S b/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S index 876707c766..b1a2b8cd65 100644 --- a/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S +++ b/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S @@ -26,8 +26,10 @@ /* float [fp1] nearbyintf(float [fp1]) */ .section ".toc","aw" + .p2align 3 .LC0: /* 2**23 */ - .tc FD_4b000000_0[TC],0x4b00000000000000 + .long 0x4b000000 + .long 0x0 .section ".text" EALIGN (__nearbyintf, 4, 0) diff --git a/sysdeps/powerpc/powerpc64/fpu/s_rintf.S b/sysdeps/powerpc/powerpc64/fpu/s_rintf.S index cb28ec748d..1887717420 100644 --- a/sysdeps/powerpc/powerpc64/fpu/s_rintf.S +++ b/sysdeps/powerpc/powerpc64/fpu/s_rintf.S @@ -19,8 +19,10 @@ #include .section ".toc","aw" + .p2align 3 .LC0: /* 2**23 */ - .tc FD_4b000000_0[TC],0x4b00000000000000 + .long 0x4b000000 + .long 0x0 .section ".text" EALIGN (__rintf, 4, 0) diff --git a/sysdeps/powerpc/powerpc64/fpu/s_roundf.S b/sysdeps/powerpc/powerpc64/fpu/s_roundf.S index 980a77bde0..4f2c851631 100644 --- a/sysdeps/powerpc/powerpc64/fpu/s_roundf.S +++ b/sysdeps/powerpc/powerpc64/fpu/s_roundf.S @@ -19,10 +19,12 @@ #include .section ".toc","aw" + .p2align 3 .LC0: /* 2**23 */ - .tc FD_4b000000_0[TC],0x4b00000000000000 + .long 0x4b000000 .LC1: /* 0.5 */ - .tc FD_3f000000_0[TC],0x3f00000000000000 + .long 0x3f000000 + .section ".text" /* float [fp1] roundf (float x [fp1]) diff --git a/sysdeps/powerpc/powerpc64/fpu/s_truncf.S b/sysdeps/powerpc/powerpc64/fpu/s_truncf.S index 5ea5f3d04a..b8fd050319 100644 --- a/sysdeps/powerpc/powerpc64/fpu/s_truncf.S +++ b/sysdeps/powerpc/powerpc64/fpu/s_truncf.S @@ -19,8 +19,10 @@ #include .section ".toc","aw" + .p2align 3 .LC0: /* 2**23 */ - .tc FD_4b000000_0[TC],0x4b00000000000000 + .long 0x4b000000 + .long 0x0 .section ".text" /* float [fp1] truncf (float x [fp1])