[PATCH]: Allow some i?86 tests to run on x86_64

Kaveh R. Ghazi ghazi@caipclassic.rutgers.edu
Wed Dec 7 03:38:00 GMT 2005


The only thing of note was that it appeared that there was nothing
linux/gnu specific in gcc.dg/pr18928-1.c, it was trying to ensure that
-fpic was available.  So I changed it to test that directly.

Tested via mainline "make check" on i686-unknown-linux-gnu and
x86_64-unknown-linux-gnu.  Okay for mainline/4.1/4.0?

		Thanks,
		--Kaveh


2005-12-06  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>

	* g++.dg/other/i386-1.C, gcc.c-torture/execute/990413-2.x,
	gcc.dg/torture/pr18582-1.c,
	gcc.target/i386/attributes-error.c: Also test on x86_64.

	* gcc.dg/pr18928-1.c: Test on all targets supporting pic.

diff -rup orig/egcc-SVN20051205/gcc/testsuite/g++.dg/other/i386-1.C egcc-SVN20051205/gcc/testsuite/g++.dg/other/i386-1.C
--- orig/egcc-SVN20051205/gcc/testsuite/g++.dg/other/i386-1.C	2005-11-23 20:00:40.000000000 -0500
+++ egcc-SVN20051205/gcc/testsuite/g++.dg/other/i386-1.C	2005-12-06 21:50:14.000000000 -0500
@@ -1,5 +1,6 @@
-/* { dg-do run { target i?86-*-* } } */
+/* { dg-do run { target i?86-*-* x86_64-*-* } } */
 /* { dg-options "-march=pentium4" } */
+/* { dg-require-effective-target ilp32 } */
 
 #include <xmmintrin.h>
 #include <stdio.h>
diff -rup orig/egcc-SVN20051205/gcc/testsuite/gcc.c-torture/execute/990413-2.x egcc-SVN20051205/gcc/testsuite/gcc.c-torture/execute/990413-2.x
--- orig/egcc-SVN20051205/gcc/testsuite/gcc.c-torture/execute/990413-2.x	2005-11-03 10:37:51.000000000 -0500
+++ egcc-SVN20051205/gcc/testsuite/gcc.c-torture/execute/990413-2.x	2005-12-06 22:16:38.000000000 -0500
@@ -1,3 +1,3 @@
 # This test is x86 specific.
-if { ! [istarget "i?86-*-*"] } { return 1 }
-return 0
+if { [istarget "i?86-*-*"] || [istarget "x86_64-*-*"] } { return 0 }
+return 1
diff -rup orig/egcc-SVN20051205/gcc/testsuite/gcc.dg/pr18928-1.c egcc-SVN20051205/gcc/testsuite/gcc.dg/pr18928-1.c
--- orig/egcc-SVN20051205/gcc/testsuite/gcc.dg/pr18928-1.c	2005-11-03 10:38:19.000000000 -0500
+++ egcc-SVN20051205/gcc/testsuite/gcc.dg/pr18928-1.c	2005-12-06 21:50:14.000000000 -0500
@@ -1,5 +1,5 @@
 /* PR rtl-optimization/18928 */
-/* { dg-do compile { target i?86-*-linux* } } */
+/* { dg-do compile { target fpic } } */
 /* { dg-options "-O2 -fPIC" } */
 
 const char *toHex( unsigned short u )
diff -rup orig/egcc-SVN20051205/gcc/testsuite/gcc.dg/torture/pr18582-1.c egcc-SVN20051205/gcc/testsuite/gcc.dg/torture/pr18582-1.c
--- orig/egcc-SVN20051205/gcc/testsuite/gcc.dg/torture/pr18582-1.c	2005-11-03 10:37:57.000000000 -0500
+++ egcc-SVN20051205/gcc/testsuite/gcc.dg/torture/pr18582-1.c	2005-12-06 21:55:06.000000000 -0500
@@ -1,4 +1,4 @@
-/* { dg-do compile { target i?86-*-* } } */
+/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
 /* { dg-options "-msse3" } */
 typedef char v16qi __attribute__((vector_size (16)));
 typedef float v4sf __attribute__((vector_size (16)));
diff -rup orig/egcc-SVN20051205/gcc/testsuite/gcc.target/i386/attributes-error.c egcc-SVN20051205/gcc/testsuite/gcc.target/i386/attributes-error.c
--- orig/egcc-SVN20051205/gcc/testsuite/gcc.target/i386/attributes-error.c	2005-11-03 10:37:55.000000000 -0500
+++ egcc-SVN20051205/gcc/testsuite/gcc.target/i386/attributes-error.c	2005-12-06 21:50:14.000000000 -0500
@@ -1,4 +1,5 @@
-/* { dg-do compile { target i?86-*-* } } */
+/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
+/* { dg-require-effective-target ilp32 } */
 
 void foo1(int i, int j) __attribute__((fastcall, cdecl)); /* { dg-error "not compatible" } */
 void foo2(int i, int j) __attribute__((fastcall, stdcall)); /* { dg-error "not compatible" } */



More information about the Gcc-patches mailing list