This is the mail archive of the glibc-cvs@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]

GNU C Library master sources branch google/grte/v5-2.27/master updated. glibc-2.27-165-g464da91


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, google/grte/v5-2.27/master has been updated
       via  464da9128b8f74750d0d1dbbf63db74738bf69ec (commit)
       via  f64e382b153320038689d0516b4fd26c2aae3b7f (commit)
       via  2b9f6ea4d6d4fb2af7e7ee5245f749d0898a41e7 (commit)
       via  3213e1c4d9413d1cabd91e6e675ec7425a5cac5c (commit)
       via  8913016212951d9eb4686d35978728e45573caae (commit)
       via  2c2196f4ef8b337a557c536d78edaa064ea86551 (commit)
       via  f26e89bca85f35f7db31648e50e617eb5c4244c7 (commit)
       via  82008f3bd7d4c33927194780b9f1501aac58f060 (commit)
       via  844afe29c7281f0fe93a9498f99c416d1afbe6a6 (commit)
       via  673e691fa29e54f655f5dcdc224f8e2422cc377c (commit)
       via  3ca2d3f3311a73f4dc96811ea987f0b5586d0407 (commit)
      from  86a18628991faaeb23eaaf5c809f08b87d5c7e9d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=464da9128b8f74750d0d1dbbf63db74738bf69ec

commit 464da9128b8f74750d0d1dbbf63db74738bf69ec
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 14:44:39 2018 -0700

    Work around mtfsb0 syntax limitation with clang

diff --git a/sysdeps/powerpc/powerpc64/fpu/s_nearbyint.S b/sysdeps/powerpc/powerpc64/fpu/s_nearbyint.S
index 7d89e78..27020c9 100644
--- a/sysdeps/powerpc/powerpc64/fpu/s_nearbyint.S
+++ b/sysdeps/powerpc/powerpc64/fpu/s_nearbyint.S
@@ -42,7 +42,11 @@ ENTRY (__nearbyint, 4)
 	fcmpu	cr7,fp1,fp12	/* if (x > 0.0) */
 	ble	cr7, L(lessthanzero)
 	mffs	fp11
+#if defined __clang__
+	mtfsb0	31	/* Disable FE_INEXACT exception */
+#else
 	mtfsb0	4*cr7+lt	/* Disable FE_INEXACT exception */
+#endif
 	fadd	fp1,fp1,fp13	/* x+= TWO52 */
 	fsub	fp1,fp1,fp13	/* x-= TWO52 */
 	fabs	fp1,fp1		/* if (x == 0.0) */
@@ -51,7 +55,11 @@ ENTRY (__nearbyint, 4)
 L(lessthanzero):
 	bgelr	cr7		/* if (x < 0.0) */
 	mffs	fp11
+#if defined __clang__
+	mtfsb0	31
+#else
 	mtfsb0	4*cr7+lt
+#endif
 	fsub	fp1,fp1,fp13	/* x -= TWO52 */
 	fadd	fp1,fp1,fp13	/* x += TWO52 */
 	fnabs	fp1,fp1		/* if (x == 0.0) */
diff --git a/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S b/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S
index 4b62ba1..0522b10 100644
--- a/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S
+++ b/sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S
@@ -43,7 +43,11 @@ ENTRY (__nearbyintf, 4)
 	fcmpu	cr7,fp1,fp12	/* if (x > 0.0)  */
 	ble	cr7, L(lessthanzero)
 	mffs	fp11
+#if defined __clang__
+	mtfsb0	31	/* Disable FE_INEXACT exception */
+#else
 	mtfsb0	4*cr7+lt	/* Disable FE_INEXACT exception */
+#endif
 	fadds	fp1,fp1,fp13	/* x += TWO23 */
 	fsubs	fp1,fp1,fp13	/* x -= TWO23 */
 	fabs	fp1,fp1		/* if (x == 0.0) */
@@ -52,7 +56,11 @@ ENTRY (__nearbyintf, 4)
 L(lessthanzero):
 	bgelr	cr7		/* if (x < 0.0) */
 	mffs	fp11
+#if defined __clang__
+	mtfsb0	31	/* Disable FE_INEXACT exception */
+#else
 	mtfsb0	4*cr7+lt	/* Disable FE_INEXACT exception */
+#endif
 	fsubs	fp1,fp1,fp13	/* x -= TWO23 */
 	fadds	fp1,fp1,fp13	/* x += TWO23 */
 	fnabs	fp1,fp1		/* if (x == 0.0) */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=f64e382b153320038689d0516b4fd26c2aae3b7f

commit f64e382b153320038689d0516b4fd26c2aae3b7f
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 14:31:55 2018 -0700

    Avoid passing gcc-specific options to clang

diff --git a/sysdeps/powerpc/powerpc64/Makefile b/sysdeps/powerpc/powerpc64/Makefile
index 9d15db0..525c6a4 100644
--- a/sysdeps/powerpc/powerpc64/Makefile
+++ b/sysdeps/powerpc/powerpc64/Makefile
@@ -10,6 +10,7 @@ ifeq (yes,$(build-shared))
 pic-ccflag = -fpic
 endif
 
+ifeq ($(with-clang),no)
 # These flags prevent FPU or Altivec registers from being used,
 # for code called in contexts that is not allowed to touch those registers.
 # Stupid GCC requires us to pass all these ridiculous switches.  We need to
@@ -40,10 +41,14 @@ ifeq ($(subdir),elf)
 +cflags += -finline-limit=2000
 endif
 
+endif # clang
+
 ifeq ($(subdir),gmon)
 # The assembly functions assume that fp arg regs are not trashed.
 # Compiling with -msoft-float ensures that fp regs are not used
 # for moving memory around.
+ifeq ($(with-clang),no)
 CFLAGS-mcount.c += $(no-special-regs)
+endif # clang
 sysdep_routines += ppc-mcount
 endif

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=2b9f6ea4d6d4fb2af7e7ee5245f749d0898a41e7

commit 2b9f6ea4d6d4fb2af7e7ee5245f749d0898a41e7
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 14:16:30 2018 -0700

    Make asm-based constraints be gcc-only

diff --git a/sysdeps/powerpc/fpu/math_private.h b/sysdeps/powerpc/fpu/math_private.h
index 4d1e571..92ed872 100644
--- a/sysdeps/powerpc/fpu/math_private.h
+++ b/sysdeps/powerpc/fpu/math_private.h
@@ -24,11 +24,13 @@
 #include <dl-procinfo.h>
 #include <fenv_private.h>
 
+#if !defined __clang__  /* clang being confused by these constraints */
 /* Avoid putting floating point values in memory.  */
 # define math_opt_barrier(x)					\
   ({ __typeof (x) __x = (x); __asm ("" : "+dwa" (__x)); __x; })
 # define math_force_eval(x)						\
   ({ __typeof (x) __x = (x); __asm __volatile__ ("" : : "dwa" (__x)); })
+#endif /* clang */
 
 #include_next <math_private.h>
 

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=3213e1c4d9413d1cabd91e6e675ec7425a5cac5c

commit 3213e1c4d9413d1cabd91e6e675ec7425a5cac5c
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 14:14:49 2018 -0700

    Make xxland syntax gcc-only

diff --git a/sysdeps/powerpc/fpu/s_float_bitwise.h b/sysdeps/powerpc/fpu/s_float_bitwise.h
index 6608692..6be2983 100644
--- a/sysdeps/powerpc/fpu/s_float_bitwise.h
+++ b/sysdeps/powerpc/fpu/s_float_bitwise.h
@@ -27,7 +27,7 @@ static inline int
 __float_and_test28 (float num, float value)
 {
   float ret;
-#ifdef _ARCH_PWR7
+#if defined _ARCH_PWR7 && !defined __clang__
   union {
     int i;
     float f;
@@ -51,7 +51,7 @@ static inline int
 __float_and_test24 (float num, float value)
 {
   float ret;
-#ifdef _ARCH_PWR7
+#if defined _ARCH_PWR7 && !defined __clang__
   union {
     int i;
     float f;
@@ -73,7 +73,7 @@ static inline float
 __float_and8 (float num)
 {
   float ret;
-#ifdef _ARCH_PWR7
+#if defined _ARCH_PWR7 && !defined __clang__
   union {
     int i;
     float f;
@@ -95,7 +95,7 @@ static inline int32_t
 __float_get_exp (float num)
 {
   int32_t inum;
-#ifdef _ARCH_PWR7
+#if defined _ARCH_PWR7 && !defined __clang__
   float ret;
   union {
     int i;

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=8913016212951d9eb4686d35978728e45573caae

commit 8913016212951d9eb4686d35978728e45573caae
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 14:04:13 2018 -0700

    Add a first approximation of float definitions for ppc clang

diff --git a/sysdeps/powerpc/bits/floatn.h b/sysdeps/powerpc/bits/floatn.h
index c383409..11aa974 100644
--- a/sysdeps/powerpc/bits/floatn.h
+++ b/sysdeps/powerpc/bits/floatn.h
@@ -22,11 +22,17 @@
 #include <features.h>
 #include <bits/long-double.h>
 
+#if 0 /* for macro expansion debugging */
+#define capture0(sym) typedef int sym##_eq_0
+#define capture1(sym) typedef int sym##_eq_1
+/*#define capture(sym, val) extern int sym[val]*/
+#endif
+
 /* Defined to 1 if the current compiler invocation provides a
    floating-point type with the IEEE 754 binary128 format, and this glibc
    includes corresponding *f128 interfaces for it.  */
 #if defined _ARCH_PWR8 && defined __LITTLE_ENDIAN__ && (_CALL_ELF == 2) \
-    && defined __FLOAT128__ && !defined __NO_LONG_DOUBLE_MATH
+    && defined __FLOAT128__ && !defined __NO_LONG_DOUBLE_MATH && !defined __clang__
 # define __HAVE_FLOAT128 1
 #else
 # define __HAVE_FLOAT128 0
@@ -52,6 +58,23 @@
 #define __HAVE_FLOAT64X_LONG_DOUBLE 0
 
 #ifndef __ASSEMBLER__
+#if 0 /* for macro expansion debugging */
+#if __HAVE_FLOAT128
+capture1(i_have_float128);
+#else
+capture0(i_have_float128);
+#endif
+#if __HAVE_DISTINCT_FLOAT128
+capture1(i_have_distinct_float128);
+#else
+capture0(i_have_distinct_float128);
+#endif
+/*capture(i_have_float128, __HAVE_FLOAT128);*/
+/*capture(i_have_distinct_float128, __HAVE_DISTINCT_FLOAT128);*/
+#endif
+#endif
+
+#ifndef __ASSEMBLER__
 
 /* Defined to concatenate the literal suffix to be used with _Float128
    types, if __HAVE_FLOAT128 is 1. */
@@ -66,7 +89,7 @@
 
 /* Defined to a complex binary128 type if __HAVE_FLOAT128 is 1.  */
 # if __HAVE_FLOAT128
-#  if !__GNUC_PREREQ (7, 0) || defined __cplusplus
+#  if !defined __clang__ && (!__GNUC_PREREQ (7, 0) || defined __cplusplus)
 /* Add a typedef for older GCC compilers which don't natively support
    _Complex _Float128.  */
 typedef _Complex float __cfloat128 __attribute__ ((__mode__ (__KC__)));
@@ -80,7 +103,7 @@ typedef _Complex float __cfloat128 __attribute__ ((__mode__ (__KC__)));
 # if __HAVE_FLOAT128
 
 /* The type _Float128 exist for powerpc only since GCC 7.0.  */
-#  if !__GNUC_PREREQ (7, 0) || defined __cplusplus
+#  if !defined __clang__ && (!__GNUC_PREREQ (7, 0) || defined __cplusplus)
 typedef __float128 _Float128;
 #  endif
 
@@ -89,6 +112,21 @@ typedef __float128 _Float128;
 #   define __builtin_huge_valf128() ((_Float128) __builtin_huge_val ())
 #  endif
 
+#if defined __clang__
+
+#if 1 /* 6.0 or less */
+#define __builtin_huge_valf128() ((_Float128) __builtin_huge_val ())
+#define __builtin_inff128() ((_Float128) __builtin_inf ())
+#define __builtin_nanf128(x) ((_Float128) __builtin_nan (x))
+#define __builtin_nansf128(x) ((_Float128) __builtin_nans (x))
+
+#define __builtin_copysignf128(x,y) ((_Float128) __builtin_copysign ((double)(x),(double)(y)))
+#define __builtin_fabsf128(x) ((_Float128) __builtin_fabs ((double)(x)))
+#define __builtin_signbitf128(x) (__builtin_signbit (x))
+#endif
+
+#else /* GCC */
+
 /* The following builtins (suffixed with 'q') are available in GCC >= 6.2,
    which is the minimum version required for float128 support on powerpc64le.
    Since GCC 7.0 the builtins suffixed with f128 are also available, then
@@ -101,6 +139,8 @@ typedef __float128 _Float128;
 #   define __builtin_nansf128 __builtin_nansq
 #  endif
 
+#endif /* GCC or clang */
+
 /* In math/math.h, __MATH_TG will expand signbit to __builtin_signbit*,
    e.g.: __builtin_signbitf128, before GCC 6.  However, there has never
    been a __builtin_signbitf128 in GCC and the type-generic builtin is
@@ -111,6 +151,10 @@ typedef __float128 _Float128;
 
 # endif
 
+#if !__HAVE_FLOAT128 && defined __clang__
+typedef long double _Float128;
+#endif /* clang fallback */
+
 #endif /* !__ASSEMBLER__.  */
 
 #include <bits/floatn-common.h>

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=2c2196f4ef8b337a557c536d78edaa064ea86551

commit 2c2196f4ef8b337a557c536d78edaa064ea86551
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 14:01:47 2018 -0700

    Make powerpc .machine directives be gcc-only

diff --git a/sysdeps/powerpc/powerpc64/__longjmp-common.S b/sysdeps/powerpc/powerpc64/__longjmp-common.S
index 0e10b8d..718d601 100644
--- a/sysdeps/powerpc/powerpc64/__longjmp-common.S
+++ b/sysdeps/powerpc/powerpc64/__longjmp-common.S
@@ -43,7 +43,7 @@
 	.section ".text"
 #endif
 
-	.machine	"altivec"
+	DOT_MACHINE ("altivec")
 ENTRY (__longjmp)
 	CALL_MCOUNT 2
 #ifndef __NO_VMX__
diff --git a/sysdeps/powerpc/powerpc64/dl-trampoline.S b/sysdeps/powerpc/powerpc64/dl-trampoline.S
index aa141dc..abff3d5 100644
--- a/sysdeps/powerpc/powerpc64/dl-trampoline.S
+++ b/sysdeps/powerpc/powerpc64/dl-trampoline.S
@@ -189,7 +189,7 @@ END(_dl_runtime_resolve)
 # endif
 	.section ".text"
 
-	.machine	"altivec"
+	DOT_MACHINE ("altivec")
 /* On entry r0 contains the index of the PLT entry we need to fixup
    and r11 contains the link_map (from PLT0+16).  The link_map becomes
    parm1 (r3) and the index (r0) needs to be converted to an offset
diff --git a/sysdeps/powerpc/powerpc64/fpu/s_isnan.S b/sysdeps/powerpc/powerpc64/fpu/s_isnan.S
index 12d2396..e4d87f2 100644
--- a/sysdeps/powerpc/powerpc64/fpu/s_isnan.S
+++ b/sysdeps/powerpc/powerpc64/fpu/s_isnan.S
@@ -20,11 +20,15 @@
 #include <math_ldbl_opt.h>
 
 /* int __isnan(x)  */
-	.machine power4
+	DOT_MACHINE ("power4")
 ENTRY_TOCLESS (__isnan, 4)
 	CALL_MCOUNT 0
 	mffs	fp0
+#if defined __clang__
+	mtfsb0	30 /* reset_fpscr_bit (FPSCR_VE) */
+#else
 	mtfsb0	4*cr6+lt /* reset_fpscr_bit (FPSCR_VE) */
+#endif
 	fcmpu	cr7,fp1,fp1
 	mtfsf	255,fp0
 	li	r3,0
diff --git a/sysdeps/powerpc/powerpc64/setjmp-common.S b/sysdeps/powerpc/powerpc64/setjmp-common.S
index ae92bb9..ede37f9 100644
--- a/sysdeps/powerpc/powerpc64/setjmp-common.S
+++ b/sysdeps/powerpc/powerpc64/setjmp-common.S
@@ -42,7 +42,7 @@
 	.section ".text"
 #endif
 
-	.machine	"altivec"
+	DOT_MACHINE ("altivec")
 ENTRY (setjmp_symbol)
 	CALL_MCOUNT 1
 	li r4,1			/* Set second argument to 1.  */
diff --git a/sysdeps/powerpc/sysdep.h b/sysdeps/powerpc/sysdep.h
index 8a6d236..4039864 100644
--- a/sysdeps/powerpc/sysdep.h
+++ b/sysdeps/powerpc/sysdep.h
@@ -166,6 +166,12 @@
 #define ALIGNARG(log2) log2
 #define ASM_SIZE_DIRECTIVE(name) .size name,.-name
 
+#if defined __clang__
+#define DOT_MACHINE(str)
+#else
+#define DOT_MACHINE(str) .machine str
+#endif
+
 #else
 
 /* Linux kernel powerpc documentation [1] states issuing a syscall inside a
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S
index 3378e62..c0ec8ea 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S
@@ -155,7 +155,7 @@ compat_symbol (libc, __novec_getcontext, getcontext, GLIBC_2_3)
 #endif
 	.section ".text"
 
-	.machine	"altivec"
+	DOT_MACHINE ("altivec")
 ENTRY(__getcontext)
 	CALL_MCOUNT 1
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3)
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S
index c95e3a1..fac26e5 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S
@@ -82,7 +82,7 @@ ENTRY(__novec_setcontext)
 # ifdef _ARCH_PWR6
   /* Use the extended four-operand version of the mtfsf insn.  */
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -93,7 +93,7 @@ ENTRY(__novec_setcontext)
   beq    5f
   /* Use the extended four-operand version of the mtfsf insn.  */
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -223,7 +223,7 @@ compat_symbol (libc, __novec_setcontext, setcontext, GLIBC_2_3)
 #endif
 
 	.section ".text"
-	.machine	"altivec"
+	DOT_MACHINE ("altivec")
 ENTRY(__setcontext)
 	CALL_MCOUNT 1
   mflr  r0
@@ -374,7 +374,7 @@ L(has_no_vec):
 # ifdef _ARCH_PWR6
   /* Use the extended four-operand version of the mtfsf insn.  */
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -385,7 +385,7 @@ L(has_no_vec):
   beq    7f
   /* Use the extended four-operand version of the mtfsf insn.  */
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -503,7 +503,7 @@ L(error_exit):
      R1 pointing at the dummy frame) state.  We do have the ucontext
      address in R3, so simply copy R3 to R1 before the syscall.  */
 L(do_sigret):
-  mr   r1,r3,
+  mr   r1,r3
   li   r0,SYS_ify(rt_sigreturn)
   sc
   /* No return.  */
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
index 50f7233..b52929c 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
@@ -178,7 +178,7 @@ ENTRY(__novec_swapcontext)
 # ifdef _ARCH_PWR6
   /* Use the extended four-operand version of the mtfsf insn.  */
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -189,7 +189,7 @@ ENTRY(__novec_swapcontext)
   beq    5f
 
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -310,7 +310,7 @@ compat_symbol (libc, __novec_swapcontext, swapcontext, GLIBC_2_3)
 #endif
 
 	.section ".text"
-	.machine	"altivec"
+	DOT_MACHINE ("altivec")
 ENTRY(__swapcontext)
 	CALL_MCOUNT 2
   std  r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3)
@@ -667,7 +667,7 @@ L(has_no_vec2):
 # ifdef _ARCH_PWR6
   /* Use the extended four-operand version of the mtfsf insn.  */
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -678,7 +678,7 @@ L(has_no_vec2):
   beq    7f
 
   .machine push
-  .machine "power6"
+  DOT_MACHINE ("power6")
 
   mtfsf  0xff,fp0,1,0
 
@@ -787,7 +787,7 @@ L(error_exit):
      R1 pointing at the dummy frame) state.  We do have the ucontext
      address in R3, so simply copy R3 to R1 before the syscall.  */
 L(do_sigret):
-  mr   r1,r3,
+  mr   r1,r3
   li   r0,SYS_ify(rt_sigreturn)
   sc
   /* No return.  */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=f26e89bca85f35f7db31648e50e617eb5c4244c7

commit f26e89bca85f35f7db31648e50e617eb5c4244c7
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 13:50:57 2018 -0700

    Make mutex hints gcc-only, improve a type in __arch_compare_and_exchange_bool_32_acq

diff --git a/sysdeps/powerpc/powerpc64/atomic-machine.h b/sysdeps/powerpc/powerpc64/atomic-machine.h
index 1f09c52..a2c7848 100644
--- a/sysdeps/powerpc/powerpc64/atomic-machine.h
+++ b/sysdeps/powerpc/powerpc64/atomic-machine.h
@@ -25,7 +25,7 @@
     adjacent to the lock word after the Store Conditional and the hint
     should be false.  */
 
-#if defined _ARCH_PWR6 || defined _ARCH_PWR6X
+#if (defined _ARCH_PWR6 || defined _ARCH_PWR6X) && !defined __clang__
 # define MUTEX_HINT_ACQ	",1"
 # define MUTEX_HINT_REL	",0"
 #else
@@ -45,7 +45,7 @@
    value as unsigned.  So we explicitly clear the high 32 bits in oldval.  */
 #define __arch_compare_and_exchange_bool_32_acq(mem, newval, oldval) \
 ({									      \
-  unsigned int __tmp, __tmp2;						      \
+  unsigned int __tmp; unsigned long __tmp2;						\
   __asm __volatile ("   clrldi  %1,%1,32\n"				      \
 		    "1:	lwarx	%0,0,%2" MUTEX_HINT_ACQ "\n"	 	      \
 		    "	subf.	%0,%1,%0\n"				      \

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=82008f3bd7d4c33927194780b9f1501aac58f060

commit 82008f3bd7d4c33927194780b9f1501aac58f060
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 13:47:46 2018 -0700

    Make power6 directives be gcc-only

diff --git a/sysdeps/powerpc/fpu/fenv_libc.h b/sysdeps/powerpc/fpu/fenv_libc.h
index 4c19d12..609f65b 100644
--- a/sysdeps/powerpc/fpu/fenv_libc.h
+++ b/sysdeps/powerpc/fpu/fenv_libc.h
@@ -35,13 +35,19 @@ extern const fenv_t *__fe_mask_env (void) attribute_hidden;
 #define fegetenv_register() \
         ({ fenv_t env; asm volatile ("mffs %0" : "=f" (env)); env; })
 
+#if defined __clang__
+#define MACHINE_POWER6
+#else
+#define MACHINE_POWER6 ".machine \"power6\""
+#endif
+
 /* Equivalent to fesetenv, but takes a fenv_t instead of a pointer.  */
 #define fesetenv_register(env) \
 	do { \
 	  double d = (env); \
 	  if(GLRO(dl_hwcap) & PPC_FEATURE_HAS_DFP) \
 	    asm volatile (".machine push; " \
-			  ".machine \"power6\"; " \
+			  MACHINE_POWER6 "; " \
 			  "mtfsf 0xff,%0,1,0; " \
 			  ".machine pop" : : "f" (d)); \
 	  else \
@@ -57,7 +63,8 @@ extern const fenv_t *__fe_mask_env (void) attribute_hidden;
 #define relax_fenv_state() \
 	do { \
 	   if (GLRO(dl_hwcap) & PPC_FEATURE_HAS_DFP) \
-	     asm (".machine push; .machine \"power6\"; " \
+	     asm (".machine push; " \
+		  MACHINE_POWER6 "; " \
 		  "mtfsfi 7,0,1; .machine pop"); \
 	   asm ("mtfsfi 7,0"); \
 	} while(0)
diff --git a/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c b/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c
index c64ca88..ad64eb8 100644
--- a/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c
+++ b/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c
@@ -104,6 +104,12 @@ typedef unsigned int si_fpscr_t __attribute__ ((__mode__ (__SI__)));
     u.fpscr;								\
   })
 
+#if defined __clang__
+#define MACHINE_POWER6
+#else
+#define MACHINE_POWER6 ".machine \"power6\""
+#endif
+
 /* We make sure to zero fp after we use it in order to prevent stale data
    in an fp register from making a test-case pass erroneously.  */
 # define _SET_DI_FPSCR(__fpscr)						\
@@ -113,7 +119,7 @@ typedef unsigned int si_fpscr_t __attribute__ ((__mode__ (__SI__)));
     fr = u.d;								\
     /* Set the entire 64-bit FPSCR.  */					\
     __asm__ (".machine push; "						\
-	     ".machine \"power6\"; "					\
+	     MACHINE_POWER6 "; "					\
 	     "mtfsf 255,%0,1,0; "					\
 	     ".machine pop" : : "f" (fr));				\
     fr = 0.0;								\

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=844afe29c7281f0fe93a9498f99c416d1afbe6a6

commit 844afe29c7281f0fe93a9498f99c416d1afbe6a6
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 13:43:57 2018 -0700

    Add power9 flag to go with -mfloat128

diff --git a/sysdeps/powerpc/powerpc64le/Makefile b/sysdeps/powerpc/powerpc64le/Makefile
index 01957b4..c4d3646 100644
--- a/sysdeps/powerpc/powerpc64le/Makefile
+++ b/sysdeps/powerpc/powerpc64le/Makefile
@@ -1,6 +1,11 @@
 # When building float128 we need to ensure -mfloat128 is
 # passed to all such object files.
 
+pow9-flag =
+ifeq ($(with-clang),yes)
+pow9-flag = -mcpu=pwr9
+endif
+
 # libgcc requires __tcb_parse_hwcap_and_convert_at_platform when built with
 # a binary128 type.  That symbol is provided by the loader on dynamically
 # linked executables, forcing to link the loader after libgcc link.
@@ -11,18 +16,18 @@ ifeq ($(subdir),math)
 CPPFLAGS += -I../soft-fp
 
 # float128 requires adding a handful of extra flags.
-$(foreach suf,$(all-object-suffixes),%f128$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),%f128_r$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),$(objpfx)test-float128%$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),$(objpfx)test-float64x%$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),$(objpfx)test-ifloat128%$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),$(objpfx)test-ifloat64x%$(suf)): CFLAGS += -mfloat128
-CFLAGS-libm-test-support-float128.c += -mfloat128
-CFLAGS-libm-test-support-float64x.c += -mfloat128
-CFLAGS-test-math-iscanonical.cc += -mfloat128
-CFLAGS-test-math-iseqsig.cc += -mfloat128
-CFLAGS-test-math-issignaling.cc += -mfloat128
-CFLAGS-test-math-iszero.cc += -mfloat128
+$(foreach suf,$(all-object-suffixes),%f128$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),%f128_r$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),$(objpfx)test-float128%$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),$(objpfx)test-float64x%$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),$(objpfx)test-ifloat128%$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),$(objpfx)test-ifloat64x%$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+CFLAGS-libm-test-support-float128.c += -mfloat128 $(pow9-flag)
+CFLAGS-libm-test-support-float64x.c += -mfloat128 $(pow9-flag)
+CFLAGS-test-math-iscanonical.cc += -mfloat128 $(pow9-flag)
+CFLAGS-test-math-iseqsig.cc += -mfloat128 $(pow9-flag)
+CFLAGS-test-math-issignaling.cc += -mfloat128 $(pow9-flag)
+CFLAGS-test-math-iszero.cc += -mfloat128 $(pow9-flag)
 $(foreach test, \
 	  test-float128% test-ifloat128% test-float64x% test-ifloat64x% \
 	  test-math-iscanonical test-math-iseqsig test-math-issignaling \
@@ -33,21 +38,21 @@ endif
 
 # Append flags to string <-> _Float128 routines.
 ifneq ($(filter $(subdir),wcsmbs stdlib),)
-$(foreach suf,$(all-object-suffixes),%f128$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),%f128_l$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),%f128_nan$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),%float1282mpn$(suf)): CFLAGS += -mfloat128
-$(foreach suf,$(all-object-suffixes),%mpn2float128$(suf)): CFLAGS += -mfloat128
-CFLAGS-bug-strtod.c += -mfloat128
-CFLAGS-bug-strtod2.c += -mfloat128
-CFLAGS-tst-strtod-round.c += -mfloat128
-CFLAGS-tst-wcstod-round.c += -mfloat128
-CFLAGS-tst-strtod-nan-locale.c += -mfloat128
-CFLAGS-tst-wcstod-nan-locale.c += -mfloat128
-CFLAGS-tst-strtod6.c += -mfloat128
-CFLAGS-tst-strfrom.c += -mfloat128
-CFLAGS-tst-strfrom-locale.c += -mfloat128
-CFLAGS-strfrom-skeleton.c += -mfloat128
+$(foreach suf,$(all-object-suffixes),%f128$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),%f128_l$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),%f128_nan$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),%float1282mpn$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+$(foreach suf,$(all-object-suffixes),%mpn2float128$(suf)): CFLAGS += -mfloat128 $(pow9-flag)
+CFLAGS-bug-strtod.c += -mfloat128 $(pow9-flag)
+CFLAGS-bug-strtod2.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-strtod-round.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-wcstod-round.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-strtod-nan-locale.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-wcstod-nan-locale.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-strtod6.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-strfrom.c += -mfloat128 $(pow9-flag)
+CFLAGS-tst-strfrom-locale.c += -mfloat128 $(pow9-flag)
+CFLAGS-strfrom-skeleton.c += -mfloat128 $(pow9-flag)
 $(foreach test,bug-strtod bug-strtod2 bug-strtod2 tst-strtod-round \
 tst-wcstod-round tst-strtod6 tst-strrom tst-strfrom-locale \
 tst-strtod-nan-locale tst-wcstod-nan-locale \
@@ -58,18 +63,19 @@ strfrom-skeleton,$(objpfx)$(test)): gnulib-tests += $(f128-loader-link)
 # Makefiles (e.g.: wcsmbs/Makefile) override CFLAGS defined by the Makefiles in
 # sysdeps.  This is avoided with the use sysdep-CFLAGS instead of CFLAGS.
 sysdep-CFLAGS += $(sysdep-CFLAGS-$(<F))
-sysdep-CFLAGS-fpioconst.c += -mfloat128
-sysdep-CFLAGS-strtod_l.c += -mfloat128
-sysdep-CFLAGS-strtof_l.c += -mfloat128
-sysdep-CFLAGS-strtold_l.c += -mfloat128
-sysdep-CFLAGS-wcstod_l.c += -mfloat128
-sysdep-CFLAGS-wcstof_l.c += -mfloat128
-sysdep-CFLAGS-wcstold_l.c += -mfloat128
+#  -mllvm -enable-ppc-quad-precision
+sysdep-CFLAGS-fpioconst.c += -mfloat128 $(pow9-flag)
+sysdep-CFLAGS-strtod_l.c += -mfloat128 $(pow9-flag)
+sysdep-CFLAGS-strtof_l.c += -mfloat128 $(pow9-flag)
+sysdep-CFLAGS-strtold_l.c += -mfloat128 $(pow9-flag)
+sysdep-CFLAGS-wcstod_l.c += -mfloat128 $(pow9-flag)
+sysdep-CFLAGS-wcstof_l.c += -mfloat128 $(pow9-flag)
+sysdep-CFLAGS-wcstold_l.c += -mfloat128 $(pow9-flag)
 endif
 
 # Append flags to printf routines.
 ifeq ($(subdir),stdio-common)
-CFLAGS-printf_fp.c = -mfloat128
-CFLAGS-printf_fphex.c = -mfloat128
-CFLAGS-printf_size.c = -mfloat128
+CFLAGS-printf_fp.c = -mfloat128 $(pow9-flag)
+CFLAGS-printf_fphex.c = -mfloat128 $(pow9-flag)
+CFLAGS-printf_size.c = -mfloat128 $(pow9-flag)
 endif

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=673e691fa29e54f655f5dcdc224f8e2422cc377c

commit 673e691fa29e54f655f5dcdc224f8e2422cc377c
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 13:36:42 2018 -0700

    Disable more attempts to pass -mlong-double-128 to clang

diff --git a/sysdeps/powerpc/powerpc64le/configure b/sysdeps/powerpc/powerpc64le/configure
index 66bb5dc..d40221b 100644
--- a/sysdeps/powerpc/powerpc64le/configure
+++ b/sysdeps/powerpc/powerpc64le/configure
@@ -1,6 +1,7 @@
 # This file is generated from configure.ac by Autoconf.  DO NOT EDIT!
  # Local configure fragment for sysdeps/powerpc/powerpc64le.
 
+if test "$with_clang" = no; then
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports binary128 floating point type" >&5
 $as_echo_n "checking if $CC supports binary128 floating point type... " >&6; }
@@ -42,6 +43,8 @@ if test "$libc_cv_compiler_powerpc64le_binary128_ok" != "yes"; then :
   critic_missing="$critic_missing binary128 floating point type (GCC >= 6.2) is required on powerpc64le."
 fi
 
+fi # clang
+
 OLD_CFLAGS="$CFLAGS"
 CFLAGS="$CFLAGS $libc_cv_cc_submachine"
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the target machine is at least POWER8" >&5
diff --git a/sysdeps/powerpc/powerpc64le/configure.ac b/sysdeps/powerpc/powerpc64le/configure.ac
index 20a49d8..d00a004 100644
--- a/sysdeps/powerpc/powerpc64le/configure.ac
+++ b/sysdeps/powerpc/powerpc64le/configure.ac
@@ -1,6 +1,8 @@
 GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
 # Local configure fragment for sysdeps/powerpc/powerpc64le.
 
+if test "$with_clang" = no; then
+
 dnl Require binary128 floating point support on powerpc64le (available in
 dnl GCC 6.2).
 AC_CACHE_CHECK([if $CC supports binary128 floating point type],
@@ -29,6 +31,8 @@ CFLAGS="$save_CFLAGS"])
 AS_IF([test "$libc_cv_compiler_powerpc64le_binary128_ok" != "yes"],
       [critic_missing="$critic_missing binary128 floating point type (GCC >= 6.2) is required on powerpc64le."])
 
+fi # clang
+
 dnl Require at least POWER8 on powerpc64le
 OLD_CFLAGS="$CFLAGS"
 CFLAGS="$CFLAGS $libc_cv_cc_submachine"
diff --git a/sysdeps/unix/sysv/linux/powerpc/configure b/sysdeps/unix/sysv/linux/powerpc/configure
index 6f883de..6d2465f 100644
--- a/sysdeps/unix/sysv/linux/powerpc/configure
+++ b/sysdeps/unix/sysv/linux/powerpc/configure
@@ -1,6 +1,7 @@
 # This file is generated from configure.ac by Autoconf.  DO NOT EDIT!
  # Local configure fragment for sysdeps/unix/sysv/linux/powerpc/.
 
+if test "$with_clang" = no; then
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC $CFLAGS -mlong-double-128 uses IBM extended format" >&5
 $as_echo_n "checking whether $CC $CFLAGS -mlong-double-128 uses IBM extended format... " >&6; }
@@ -76,4 +77,6 @@ $as_echo "$libc_cv_mabi_ibmlongdouble" >&6; }
   fi
 fi
 
+fi # clang
+
 ldd_rewrite_script=sysdeps/unix/sysv/linux/powerpc/ldd-rewrite.sed
diff --git a/sysdeps/unix/sysv/linux/powerpc/configure.ac b/sysdeps/unix/sysv/linux/powerpc/configure.ac
index b8e5f9a..d3e1207 100644
--- a/sysdeps/unix/sysv/linux/powerpc/configure.ac
+++ b/sysdeps/unix/sysv/linux/powerpc/configure.ac
@@ -2,6 +2,8 @@ sinclude(./aclocal.m4)dnl Autoconf lossage
 GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
 # Local configure fragment for sysdeps/unix/sysv/linux/powerpc/.
 
+if test "$with_clang" = no; then
+
 AC_CACHE_CHECK(whether $CC $CFLAGS -mlong-double-128 uses IBM extended format,
 	       libc_cv_mlong_double_128ibm, [dnl
 save_CFLAGS="$CFLAGS"
@@ -36,4 +38,6 @@ long double foobar (long double x) { return x; }],
   fi
 fi
 
+fi # clang
+
 ldd_rewrite_script=sysdeps/unix/sysv/linux/powerpc/ldd-rewrite.sed

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=3ca2d3f3311a73f4dc96811ea987f0b5586d0407

commit 3ca2d3f3311a73f4dc96811ea987f0b5586d0407
Author: Stan Shebs <stanshebs@google.com>
Date:   Wed Sep 26 13:13:31 2018 -0700

    Disable attempts to pass -mlong-double-128 to clang

diff --git a/sysdeps/ieee754/float128/Makeconfig b/sysdeps/ieee754/float128/Makeconfig
index 99ae5e0..24d023c 100644
--- a/sysdeps/ieee754/float128/Makeconfig
+++ b/sysdeps/ieee754/float128/Makeconfig
@@ -1,4 +1,9 @@
 # Include this earlier so it can be used earlier in Makefiles,
 # and sysdep/ makefiles.
 float128-fcts = $(enable-float128)
+# on ppc, float64x is tied to float128
+ifeq ($(findstring powerpc,$(config-sysdirs)),powerpc)
+float64x-alias-fcts = $(enable-float128)
+else
 float64x-alias-fcts = yes
+endif
diff --git a/sysdeps/ieee754/ldbl-128ibm/Makefile b/sysdeps/ieee754/ldbl-128ibm/Makefile
index bdba6cc..c303154 100644
--- a/sysdeps/ieee754/ldbl-128ibm/Makefile
+++ b/sysdeps/ieee754/ldbl-128ibm/Makefile
@@ -2,7 +2,9 @@
 # -mlong-double-128 option is used (or when it becomes a default
 # when -mlong-double-64 is not used).
 long-double-fcts = yes
+ifneq ($(with-clang),yes)
 sysdep-CFLAGS += -mlong-double-128
+endif
 
 ifeq ($(subdir),stdlib)
 tests += tst-strtold-ldbl-128ibm
@@ -14,3 +16,98 @@ tests += test-fmodl-ldbl-128ibm test-remainderl-ldbl-128ibm \
 	 test-remquol-ldbl-128ibm test-canonical-ldbl-128ibm \
 	 test-totalorderl-ldbl-128ibm
 endif
+
+# clang crashing a lot trying to optimize any of this
+ifeq ($(with-clang),yes)
+CFLAGS-test-canonical-ldbl-128ibm.c = -O0
+CFLAGS-test-totalorderl-ldbl-128ibm.c = -O0
+
+CFLAGS-e_acoshl.c = -O0
+CFLAGS-e_acosl.c = -O0
+CFLAGS-e_asinl.c = -O0
+CFLAGS-e_atan2l.c = -O0
+CFLAGS-e_atanhl.c = -O0
+CFLAGS-e_coshl.c = -O0
+CFLAGS-e_exp10l.c = -O0
+CFLAGS-e_expl.c = -O0
+CFLAGS-e_fmodl.c = -O0
+CFLAGS-e_gammal_r.c = -O0
+CFLAGS-e_hypotl.c = -O0
+CFLAGS-e_ilogbl.c = -O0
+CFLAGS-e_j0l.c = -O0
+CFLAGS-e_j1l.c = -O0
+CFLAGS-e_jnl.c = -O0
+CFLAGS-e_lgammal_r.c = -O0
+CFLAGS-e_log10l.c = -O0
+CFLAGS-e_log2l.c = -O0
+CFLAGS-e_logl.c = -O0
+CFLAGS-e_powl.c = -O0
+CFLAGS-e_remainderl.c = -O0
+CFLAGS-e_rem_pio2l.c = -O0
+CFLAGS-e_sinhl.c = -O0
+CFLAGS-e_sqrtl.c = -O0
+CFLAGS-gamma_productl.c = -O0
+CFLAGS-k_cosl.c = -O0
+CFLAGS-k_sincosl.c = -O0
+CFLAGS-k_sinl.c = -O0
+CFLAGS-k_tanl.c = -O0
+CFLAGS-ldbl2mpn.c = -O0
+CFLAGS-lgamma_negl.c = -O0
+CFLAGS-lgamma_productl.c = -O0
+CFLAGS-mpn2ldbl.c = -O0
+CFLAGS-printf_fphex.c = -O0
+CFLAGS-s_asinhl.c = -O0
+CFLAGS-s_atanl.c = -O0
+CFLAGS-s_cbrtl.c = -O0
+CFLAGS-s_ceill.c = -O0
+CFLAGS-s_copysignl.c = -O0
+CFLAGS-s_cosl.c = -O0
+CFLAGS-s_erfl.c = -O0
+CFLAGS-s_expm1l.c = -O0
+CFLAGS-s_fabsl.c = -O0
+CFLAGS-s_finitel.c = -O0
+CFLAGS-s_floorl.c = -O0
+CFLAGS-s_fmal.c = -O0
+CFLAGS-s_fpclassifyl.c = -O0
+CFLAGS-s_frexpl.c = -O0
+CFLAGS-s_fromfpl.c = -O0
+CFLAGS-s_fromfpl_main.c = -O0
+CFLAGS-s_fromfpxl.c = -O0
+CFLAGS-s_getpayloadl.c = -O0
+CFLAGS-s_iscanonicall.c = -O0
+CFLAGS-s_isinfl.c = -O0
+CFLAGS-s_isnanl.c = -O0
+CFLAGS-s_issignalingl.c = -O0
+CFLAGS-s_llrintl.c = -O0
+CFLAGS-s_llroundl.c = -O0
+CFLAGS-s_log1pl.c = -O0
+CFLAGS-s_logbl.c = -O0
+CFLAGS-s_lrintl.c = -O0
+CFLAGS-s_lroundl.c = -O0
+CFLAGS-s_modfl.c = -O0
+CFLAGS-s_nearbyintl.c = -O0
+CFLAGS-s_nextafterl.c = -O0
+CFLAGS-s_nexttoward.c = -O0
+CFLAGS-s_nexttowardf.c = -O0
+CFLAGS-s_nextupl.c = -O0
+CFLAGS-s_remquol.c = -O0
+CFLAGS-s_rintl.c = -O0
+CFLAGS-s_roundevenl.c = -O0
+CFLAGS-s_roundl.c = -O0
+CFLAGS-s_scalblnl.c = -O0
+CFLAGS-s_scalbnl.c = -O0
+CFLAGS-s_setpayloadl.c = -O0
+CFLAGS-s_setpayloadl_main.c = -O0
+CFLAGS-s_setpayloadsigl.c = -O0
+CFLAGS-s_signbitl.c = -O0
+CFLAGS-s_sincosl.c = -O0
+CFLAGS-s_sinl.c = -O0
+CFLAGS-s_tanhl.c = -O0
+CFLAGS-s_tanl.c = -O0
+CFLAGS-s_totalorderl.c = -O0
+CFLAGS-s_totalordermagl.c = -O0
+CFLAGS-s_truncl.c = -O0
+CFLAGS-s_ufromfpl.c = -O0
+CFLAGS-s_ufromfpxl.c = -O0
+CFLAGS-t_sincosl.c = -O0
+endif
diff --git a/sysdeps/ieee754/ldbl-opt/Makefile b/sysdeps/ieee754/ldbl-opt/Makefile
index ffc55d1..ab8ee24 100644
--- a/sysdeps/ieee754/ldbl-opt/Makefile
+++ b/sysdeps/ieee754/ldbl-opt/Makefile
@@ -2,9 +2,12 @@
 # -mlong-double-128 option is used (or when it becomes a default
 # when -mlong-double-64 is not used).
 long-double-fcts = yes
+# Skip this for clang (or stub out whole dir?)
+ifeq ($(with-clang),no)
 ifeq (,$(filter -mlong-double-128,$(sysdep-CFLAGS)))
 sysdep-CFLAGS += -mlong-double-128
 endif
+endif
 
 ifeq ($(subdir),math)
 libm-routines += s_nexttowardfd
diff --git a/sysdeps/ieee754/ldbl-opt/configure b/sysdeps/ieee754/ldbl-opt/configure
index ad9d77b..779fd82 100644
--- a/sysdeps/ieee754/ldbl-opt/configure
+++ b/sysdeps/ieee754/ldbl-opt/configure
@@ -1,6 +1,7 @@
 # This file is generated from configure.ac by Autoconf.  DO NOT EDIT!
  # Local configure fragment for sysdeps/ieee754/ldbl-opt/.
 
+if test "$with_clang" = no; then
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC $CFLAGS supports -mlong-double-128" >&5
 $as_echo_n "checking whether $CC $CFLAGS supports -mlong-double-128... " >&6; }
@@ -37,3 +38,5 @@ $as_echo "$libc_cv_mlong_double_128" >&6; }
 if test "$libc_cv_mlong_double_128" = no; then
   as_fn_error $? "this configuration requires -mlong-double-128 support" "$LINENO" 5
 fi
+
+fi # with_clang
diff --git a/sysdeps/ieee754/ldbl-opt/configure.ac b/sysdeps/ieee754/ldbl-opt/configure.ac
index a77fadd..69ee576 100644
--- a/sysdeps/ieee754/ldbl-opt/configure.ac
+++ b/sysdeps/ieee754/ldbl-opt/configure.ac
@@ -2,6 +2,8 @@ sinclude(./aclocal.m4)dnl Autoconf lossage
 GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
 # Local configure fragment for sysdeps/ieee754/ldbl-opt/.
 
+if test "$with_clang" = no; then
+
 AC_CACHE_CHECK(whether $CC $CFLAGS supports -mlong-double-128,
 	       libc_cv_mlong_double_128, [dnl
 save_CFLAGS="$CFLAGS"
@@ -17,3 +19,5 @@ CFLAGS="$save_CFLAGS"])
 if test "$libc_cv_mlong_double_128" = no; then
   AC_MSG_ERROR([this configuration requires -mlong-double-128 support])
 fi
+
+fi # with_clang

-----------------------------------------------------------------------

Summary of changes:
 sysdeps/ieee754/float128/Makeconfig                |    5 +
 sysdeps/ieee754/ldbl-128ibm/Makefile               |   97 ++++++++++++++++++++
 sysdeps/ieee754/ldbl-opt/Makefile                  |    3 +
 sysdeps/ieee754/ldbl-opt/configure                 |    3 +
 sysdeps/ieee754/ldbl-opt/configure.ac              |    4 +
 sysdeps/powerpc/bits/floatn.h                      |   50 ++++++++++-
 sysdeps/powerpc/fpu/fenv_libc.h                    |   11 ++-
 sysdeps/powerpc/fpu/math_private.h                 |    2 +
 sysdeps/powerpc/fpu/s_float_bitwise.h              |    8 +-
 sysdeps/powerpc/fpu/tst-setcontext-fpscr.c         |    8 ++-
 sysdeps/powerpc/powerpc64/Makefile                 |    5 +
 sysdeps/powerpc/powerpc64/__longjmp-common.S       |    2 +-
 sysdeps/powerpc/powerpc64/atomic-machine.h         |    4 +-
 sysdeps/powerpc/powerpc64/dl-trampoline.S          |    2 +-
 sysdeps/powerpc/powerpc64/fpu/s_isnan.S            |    6 +-
 sysdeps/powerpc/powerpc64/fpu/s_nearbyint.S        |    8 ++
 sysdeps/powerpc/powerpc64/fpu/s_nearbyintf.S       |    8 ++
 sysdeps/powerpc/powerpc64/setjmp-common.S          |    2 +-
 sysdeps/powerpc/powerpc64le/Makefile               |   80 +++++++++--------
 sysdeps/powerpc/powerpc64le/configure              |    3 +
 sysdeps/powerpc/powerpc64le/configure.ac           |    4 +
 sysdeps/powerpc/sysdep.h                           |    6 +
 sysdeps/unix/sysv/linux/powerpc/configure          |    3 +
 sysdeps/unix/sysv/linux/powerpc/configure.ac       |    4 +
 .../unix/sysv/linux/powerpc/powerpc64/getcontext.S |    2 +-
 .../unix/sysv/linux/powerpc/powerpc64/setcontext.S |   12 +-
 .../sysv/linux/powerpc/powerpc64/swapcontext.S     |   12 +-
 27 files changed, 288 insertions(+), 66 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


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