about summary refs log tree commit diff
path: root/sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile
diff options
context:
space:
mode:
authorPaul E. Murphy <murphyp@linux.vnet.ibm.com>2020-02-07 14:08:12 -0600
committerPaul E. Murphy <murphyp@linux.vnet.ibm.com>2020-04-06 10:23:58 -0500
commit6f82d05034178eee756dfe09472948130748ad39 (patch)
tree9bc130f25a841a55889415d0b231c7a940863b2f /sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile
parent25ee3931f03cae31f5006c438d939544f717666a (diff)
downloadglibc-6f82d05034178eee756dfe09472948130748ad39.tar.gz
glibc-6f82d05034178eee756dfe09472948130748ad39.tar.xz
glibc-6f82d05034178eee756dfe09472948130748ad39.zip
powerpc64le: Enforce -mabi=ibmlongdouble when -mfloat128 used
I have observed a bug on 7.4.0 whereby __mulkc3 calls are
swapped with __multc3 depending on ABI selection.  For the
sake of being overly cautious, build all _Float128 files
with ibm128 to workaround these compilers.  This has been
noted in GCC BZ 84914, and will not be fixed for GCC 7.

Likewise, non-math files built with _Float128 are assumed
to have ibm long double.  Explicilty preserve this
assumption.

Finally, add some bootstrapping code to avoid applying
these options until IEEE long double is enabled as they
require GCC 7 and above.

Reviewed-by: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
Diffstat (limited to 'sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile')
-rw-r--r--sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile8
1 files changed, 4 insertions, 4 deletions
diff --git a/sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile b/sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile
index 6fb9eb3a98..8747b02127 100644
--- a/sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile
+++ b/sysdeps/powerpc/powerpc64/le/fpu/multiarch/Makefile
@@ -2,9 +2,9 @@ ifeq ($(subdir),math)
 libm-sysdep_routines += s_fmaf128-ppc64 s_fmaf128-power9 \
 			w_sqrtf128-power9 w_sqrtf128-ppc64le
 
-CFLAGS-s_fmaf128-ppc64.c += -mfloat128 $(no-gnu-attribute-CFLAGS)
-CFLAGS-s_fmaf128-power9.c += -mfloat128 -mcpu=power9 $(no-gnu-attribute-CFLAGS)
+CFLAGS-s_fmaf128-ppc64.c += $(type-float128-CFLAGS) $(no-gnu-attribute-CFLAGS)
+CFLAGS-s_fmaf128-power9.c += $(type-float128-CFLAGS) -mcpu=power9 $(no-gnu-attribute-CFLAGS)
 
-CFLAGS-w_sqrtf128-ppc64le.c += -mfloat128 $(no-gnu-attribute-CFLAGS)
-CFLAGS-w_sqrtf128-power9.c += -mfloat128 -mcpu=power9 $(no-gnu-attribute-CFLAGS)
+CFLAGS-w_sqrtf128-ppc64le.c += $(type-float128-CFLAGS) $(no-gnu-attribute-CFLAGS)
+CFLAGS-w_sqrtf128-power9.c += $(type-float128-CFLAGS) -mcpu=power9 $(no-gnu-attribute-CFLAGS)
 endif