[v2,05/10] powerpc64le: workaround ieee long double / _Float128 stdc++ bug

Message ID 20200327211801.31234-6-murphyp@linux.vnet.ibm.com
State Superseded
Headers
Series IEEE binary128 long double on powerpc64le |

Commit Message

Paul E. Murphy March 27, 2020, 9:17 p.m. UTC
  -mabi=ieeelongdouble triggers the stdc++ libraries _Float128
support, which then breaks if algorithm is included.  For now,
explicitly disable _Float128 for such tests.

I have opened up GCC BZ 94080 to track this.
---
 sysdeps/powerpc/powerpc64/le/Makefile | 11 +++++++++++
 1 file changed, 11 insertions(+)
  

Comments

Tulio Magno Quites Machado Filho April 3, 2020, 7:03 p.m. UTC | #1
"Paul E. Murphy via Libc-alpha" <libc-alpha@sourceware.org> writes:

> diff --git a/sysdeps/powerpc/powerpc64/le/Makefile b/sysdeps/powerpc/powerpc64/le/Makefile
> index 441a8a14e5..9ba7f850ad 100644
> --- a/sysdeps/powerpc/powerpc64/le/Makefile
> +++ b/sysdeps/powerpc/powerpc64/le/Makefile
> @@ -140,3 +140,14 @@ $(foreach suf,$(all-object-suffixes), $(ldbl-ibm128-files)) \
>  	  $(foreach r,$(ldbl-128ibm-routines) $(ldbl-tests), \
>  		    $(objpfx)$(r)$(suf)): \
>    sysdep-CFLAGS := $(filter-out -mabi=ieeelongdouble,$(sysdep-CFLAGS))
> +
> +# TODO: a bug in stdc++ will fail if -mabi=ieeelongdouble and -mfloat128
> +# are both enabled. The latter is enabled by default in GCC 8+.  This is

2 spaces -------------^

LGTM with that fix.

Reviewed-by: Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
  

Patch

diff --git a/sysdeps/powerpc/powerpc64/le/Makefile b/sysdeps/powerpc/powerpc64/le/Makefile
index 441a8a14e5..9ba7f850ad 100644
--- a/sysdeps/powerpc/powerpc64/le/Makefile
+++ b/sysdeps/powerpc/powerpc64/le/Makefile
@@ -140,3 +140,14 @@  $(foreach suf,$(all-object-suffixes), $(ldbl-ibm128-files)) \
 	  $(foreach r,$(ldbl-128ibm-routines) $(ldbl-tests), \
 		    $(objpfx)$(r)$(suf)): \
   sysdep-CFLAGS := $(filter-out -mabi=ieeelongdouble,$(sysdep-CFLAGS))
+
+# TODO: a bug in stdc++ will fail if -mabi=ieeelongdouble and -mfloat128
+# are both enabled. The latter is enabled by default in GCC 8+.  This is
+# tracked via GCC BZ 94080.
+ifeq ($(subdir),support)
+CFLAGS-links-dso-program.cc += -mno-float128
+endif
+ifeq ($(subdir),nptl)
+CFLAGS-tst-thread_local1.cc += -mno-float128
+CFLAGS-tst-minstack-throw.cc += -mno-float128
+endif