diff options
author | Michael Meissner <meissner@linux.vnet.ibm.com> | 2016-04-11 19:45:35 +0000 |
---|---|---|
committer | Michael Meissner <meissner@gcc.gnu.org> | 2016-04-11 19:45:35 +0000 |
commit | 35fbda430dff88d550d1c73d4499f0c6aceece4e (patch) | |
tree | 17fc7642002652c4807a5bd71789fcefe83fb7db /libgcc/configure.ac | |
parent | a9c2f3d9af1ba5ef57d98bd48b5f1689b42082e5 (diff) | |
download | gcc-35fbda430dff88d550d1c73d4499f0c6aceece4e.zip gcc-35fbda430dff88d550d1c73d4499f0c6aceece4e.tar.gz gcc-35fbda430dff88d550d1c73d4499f0c6aceece4e.tar.bz2 |
re PR target/70381 (On powerpc, -mfloat128 is on by default for all VSX systems)
[gcc]
2016-04-11 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/70381
* config/rs6000/rs6000.c (rs6000_opt_masks): Disable using the
target attribute and pragma from changing the -mfloat128
and -mfloat128-hardware options.
* doc/extend.texi (Additional Floating Types): Document PowerPC
__float128 restrictions.
[libgcc]
2016-04-11 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/70381
* configure.ac (powerpc*-*-linux*): Rework tests to build
__float128 emulation routines to not depend on using #pragma GCC
target to enable -mfloat128.
* configure: Regnerate.
[gcc/testsuite]
2016-04-11 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/70381
* gcc.target/powerpc/float128-1.c: New tests to make sure the
__float128 emulator is built and runs.
* gcc.target/powerpc/float128-1.c: Likewise.
* lib/target-supports.exp (check_ppc_float128_sw_available):
Rework tests for __float128 software and hardware
availability. Fix exit condition to return 0 on success.
From-SVN: r234884
Diffstat (limited to 'libgcc/configure.ac')
-rw-r--r-- | libgcc/configure.ac | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/libgcc/configure.ac b/libgcc/configure.ac index 897259e..269997f 100644 --- a/libgcc/configure.ac +++ b/libgcc/configure.ac @@ -374,26 +374,30 @@ esac esac case ${host} in +# At present, we cannot turn -mfloat128 on via #pragma GCC target, +# so just check if we have VSX (ISA 2.06) support to build the +# software libraries, and whether the assembler can handle xsaddqp +# for hardware support. powerpc*-*-linux*) - AC_CACHE_CHECK([whether the PowerPC compiler can do __float128], + AC_CACHE_CHECK([for PowerPC ISA 2.06 to build __float128 libraries], [libgcc_cv_powerpc_float128], [AC_COMPILE_IFELSE( - [#pragma GCC target ("vsx,float128") - __float128 add (__float128 *a) { return *a + *(a+1); }], + [#pragma GCC target ("vsx") + vector double dadd (vector double a, vector double b) { return a + b; }], [libgcc_cv_powerpc_float128=yes], [libgcc_cv_powerpc_float128=no])]) - AC_CACHE_CHECK([whether the PowerPC compiler can do hardware __float128], + AC_CACHE_CHECK([for PowerPC ISA 3.0 to build hardware __float128 libraries], [libgcc_cv_powerpc_float128_hw], [AC_COMPILE_IFELSE( - [#pragma GCC target ("cpu=power9,float128,float128-hardware") + [#pragma GCC target ("vsx,power9-vector") #include <sys/auxv.h> #ifndef AT_PLATFORM #error "AT_PLATFORM is not defined" #endif - __float128 add (__float128 a, __float128 b) + vector unsigned char (vector unsigned char a, vector unsigned char b) { - __float128 ret; + vector unsigned char ret; __asm__ ("xsaddqp %0,%1,%2" : "=v" (ret) : "v" (a), "v" (b)); return ret; } |