Patchwork [committed] Fix PR 50988, powerpc testsuite failures

login
register
mail settings
Submitter Michael Meissner
Date Dec. 29, 2011, 6:38 p.m.
Message ID <20111229183847.GA13020@ibm-tiger.the-meissners.org>
Download mbox | patch
Permalink /patch/133591/
State New
Headers show

Comments

Michael Meissner - Dec. 29, 2011, 6:38 p.m.
I committed the following patch as obvious to fix some testsuite failures on
the PowerPC SPE.  I did verify that they don't cause any regressions on
powerpc-linux.

2011-12-29  Michael Meissner  <meissner@linux.vnet.ibm.com>

	PR testsuite/50988
	* gcc.target/powerpc/altivec-34.c: Require altivec support.

	* gcc.target/powerpc/ppc-pow.c: Require VSX support so that we can
	assume standard power floating point, but not have to worry about
	running on Apple systems.

	* gcc.target/powerpc/ehreturn.c: Change the scan-assembler line to
	allow for E500 floating point.

Patch

Index: gcc/testsuite/gcc.target/powerpc/ehreturn.c
===================================================================
--- gcc/testsuite/gcc.target/powerpc/ehreturn.c	(revision 182710)
+++ gcc/testsuite/gcc.target/powerpc/ehreturn.c	(working copy)
@@ -12,4 +12,4 @@  void foo ()
   __builtin_eh_return (l, p);
 }
 
-/* { dg-final { scan-assembler "st\[wd\] 30," } } */
+/* { dg-final { scan-assembler "(st\[wd\]|evstdd) 30," } } */
Index: gcc/testsuite/gcc.target/powerpc/ppc-pow.c
===================================================================
--- gcc/testsuite/gcc.target/powerpc/ppc-pow.c	(revision 182710)
+++ gcc/testsuite/gcc.target/powerpc/ppc-pow.c	(working copy)
@@ -1,6 +1,9 @@ 
 /* { dg-do compile { target { { powerpc*-*-* } && { ! powerpc*-apple-darwin* } } } } */
-/* { dg-require-effective-target powerpc_fprs } */
-/* { dg-options "-O2 -ffast-math -mcpu=power6" } */
+/* Check for VSX here, even though we don't use VSX to eliminate SPE, PAIRED
+   and other ppc floating point varients.  However, we need to also eliminate
+   Darwin, since it doesn't like -mcpu=power6.  */
+/* { dg-require-effective-target powerpc_vsx_ok } */
+/* { dg-options "-O2 -ffast-math -mcpu=power6 -mno-vsx -mno-altivec" } */
 /* { dg-final { scan-assembler-times "fsqrt" 3 } } */
 /* { dg-final { scan-assembler-times "fmul" 1 } } */
 /* { dg-final { scan-assembler-times "bl? pow" 1 } } */
Index: gcc/testsuite/gcc.target/powerpc/altivec-34.c
===================================================================
--- gcc/testsuite/gcc.target/powerpc/altivec-34.c	(revision 182710)
+++ gcc/testsuite/gcc.target/powerpc/altivec-34.c	(working copy)
@@ -1,6 +1,7 @@ 
 /* PR target/49621 */
 /* { dg-do compile } */
-/* { dg-options "-O2 -maltivec" } */
+/* { dg-require-effective-target powerpc_altivec_ok } */
+/* { dg-options "-O2 -maltivec -mno-vsx" } */
 
 #include <altivec.h>