Patchwork [i386] : Add -march=k8 to some testcases

login
register
mail settings
Submitter Uros Bizjak
Date Feb. 10, 2011, 7:05 p.m.
Message ID <AANLkTin=crfJtU174Jgee03q1JAkApNEdH4XjwvyJ6m0@mail.gmail.com>
Download mbox | patch
Permalink /patch/82653/
State New
Headers show

Comments

Uros Bizjak - Feb. 10, 2011, 7:05 p.m.
Hello!

Some assembler scan tests are valid only for older ISAs; newer ISAs
generate different instruction sequences. See i.e. [1].

2011-02-10  Uros Bizjak  <ubizjak@gmail.com>

	* gcc.target/i386/parity-1.c: Use -march=k8.
	* gcc.target/i386/parity-2.c: Ditto.
	* gcc.target/i386/vecinit-1.c: Ditto.
	* gcc.target/i386/vecinit-2.c: Ditto.

Tested on x86_64-pc-linux-gnu {,-m32}, committed to mainline SVN.

[1] http://gcc.gnu.org/ml/gcc-testresults/2011-02/msg01097.html

Uros.

Patch

Index: gcc.target/i386/parity-1.c
===================================================================
--- gcc.target/i386/parity-1.c	(revision 170004)
+++ gcc.target/i386/parity-1.c	(working copy)
@@ -1,5 +1,5 @@ 
 /* { dg-do compile } */
-/* { dg-options "-O2" } */
+/* { dg-options "-O2 -march=k8" } */
 /* { dg-final { scan-assembler "setnp" } } */
 
 int foo(unsigned int x)
Index: gcc.target/i386/vecinit-2.c
===================================================================
--- gcc.target/i386/vecinit-2.c	(revision 170004)
+++ gcc.target/i386/vecinit-2.c	(working copy)
@@ -1,5 +1,5 @@ 
 /* { dg-do compile } */
-/* { dg-options "-O2 -msse2" } */
+/* { dg-options "-O2 -march=k8 -msse2" } */
 
 #define vector __attribute__((vector_size(16)))
 
Index: gcc.target/i386/vecinit-1.c
===================================================================
--- gcc.target/i386/vecinit-1.c	(revision 170004)
+++ gcc.target/i386/vecinit-1.c	(working copy)
@@ -1,5 +1,5 @@ 
 /* { dg-do compile } */
-/* { dg-options "-O2 -msse2" } */
+/* { dg-options "-O2 -march=k8 -msse2" } */
 
 #define vector __attribute__((vector_size(16)))
 
Index: gcc.target/i386/parity-2.c
===================================================================
--- gcc.target/i386/parity-2.c	(revision 170004)
+++ gcc.target/i386/parity-2.c	(working copy)
@@ -1,5 +1,5 @@ 
 /* { dg-do compile } */
-/* { dg-options "-O2" } */
+/* { dg-options "-O2 -march=k8" } */
 /* { dg-final { scan-assembler "setnp" } } */
 
 int foo(unsigned long long int x)