]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Darwin, PPC, testsuite, backport fix for bmi2-bzhi64-1a.c
authorIain Sandoe <iain@sandoe.co.uk>
Sun, 4 Aug 2019 13:17:15 +0000 (13:17 +0000)
committerIain Sandoe <iains@gcc.gnu.org>
Sun, 4 Aug 2019 13:17:15 +0000 (13:17 +0000)
This test is failing with older cpus because the included header needs both
altivec and vsx to be enabled to succeed in compiling. Without this (if these
are not defaults for the cpu) there are errors like:

In file included from ... x86intrin.h:41,
from ... bmi2-bzhi64-1a.c:6:
... xmmintrin.h: In function '_mm_loadu_ps':
... xmmintrin.h:122:11:
error: incompatible types when returning type 'int' but '__m128' {aka '__vector(4) float'} was expected
<snip>
... xmmintrin.h: In function '_mm_cvtps_pi32':
... xmmintrin.h:996:3:
error: use of 'long long' in AltiVec types is invalid without '-mvsx'
<snip>

Fixed by adding -maltivec -mvsx to the options

2019-08-04  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-07-27  Iain Sandoe  <iain@sandoe.co.uk>

* gcc.target/powerpc/bmi2-bzhi64-1a.c: Add options to enable altivec
and vsx.

From-SVN: r274093

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/powerpc/bmi2-bzhi64-1a.c

index bc91a791863d6d6755f9899b0934f73ff4352c07..542abb249ec7a8459ba32e781772143fb97934fa 100644 (file)
@@ -1,3 +1,11 @@
+2019-08-04  Iain Sandoe  <iain@sandoe.co.uk>
+
+       Backport from mainline.
+       2019-07-27  Iain Sandoe  <iain@sandoe.co.uk>
+
+       * gcc.target/powerpc/bmi2-bzhi64-1a.c: Add options to enable altivec
+       and vsx.
+
 2019-08-04  Iain Sandoe  <iain@sandoe.co.uk>
 
        Backport from mainline.
index 149cbc5d4168b9c86e6c5ec2a4f660f026da81cc..89bee61f0445d51e96d0c22fc07bdd030a58e30d 100644 (file)
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options "-O3" } */
+/* { dg-options "-O3 -maltivec -mvsx" } */
 /* { dg-require-effective-target lp64 } */
 
 #define NO_WARN_X86_INTRINSICS 1