diff options
author | Michael Meissner <meissner@linux.vnet.ibm.com> | 2017-09-01 22:10:57 +0000 |
---|---|---|
committer | Michael Meissner <meissner@gcc.gnu.org> | 2017-09-01 22:10:57 +0000 |
commit | 0c949f0a1ce9cfa8c48e62628493140d60e65ea7 (patch) | |
tree | 19ec6e67a88c3251f2fa78dbe04a44c337eaeaf0 /libquadmath/quadmath.h | |
parent | fe920c2d9f479c2b17d6963973cf11efe0169293 (diff) | |
download | gcc-0c949f0a1ce9cfa8c48e62628493140d60e65ea7.zip gcc-0c949f0a1ce9cfa8c48e62628493140d60e65ea7.tar.gz gcc-0c949f0a1ce9cfa8c48e62628493140d60e65ea7.tar.bz2 |
re PR libquadmath/81848 (Add PowerPC support to libquadmath)
2017-09-01 Michael Meissner <meissner@linux.vnet.ibm.com>
PR libquadmath/81848
* configure.ac (powerpc*-linux*): Use attribute mode KC to create
complex __float128 on PowerPC instead of attribute mode TC.
* quadmath.h (__complex128): Likewise.
* configure: Regenerate.
* math/cbrtq.c (CBRT2): Use __float128 not long double.
(CBRT4): Likewise.
(CBRT2I): Likewise.
(CBRT4I): Likewise.
* math/j0q.c (U0): Likewise.
* math/sqrtq.c (sqrtq): Don't depend on implicit conversion
between __float128, instead explicitly convert the __float128
value to long double because the PowerPC does not allow __float128
and long double in the same expression.
From-SVN: r251613
Diffstat (limited to 'libquadmath/quadmath.h')
-rw-r--r-- | libquadmath/quadmath.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libquadmath/quadmath.h b/libquadmath/quadmath.h index 1555304..95487b7 100644 --- a/libquadmath/quadmath.h +++ b/libquadmath/quadmath.h @@ -29,7 +29,11 @@ extern "C" { /* Define the complex type corresponding to __float128 ("_Complex __float128" is not allowed) */ +#if (!defined(_ARCH_PPC)) || defined(__LONG_DOUBLE_IEEE128__) typedef _Complex float __attribute__((mode(TC))) __complex128; +#else +typedef _Complex float __attribute__((mode(KC))) __complex128; +#endif #ifdef __cplusplus # define __quadmath_throw throw () |