This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Patch for sparc specific XFAILs in execute/20020227-1.x


While most (all) 64-bit platforms fail execute/20020227-1.c at all
optimization levels, sparc wants to be difficult. :-)

This patch eliminates the spurious XPASSes for sparc at -O0/-O1 in the
various curcumstances where the test works.  E.g. see:
http://gcc.gnu.org/ml/gcc-testresults/2003-02/msg00246.html
http://gcc.gnu.org/ml/gcc-testresults/2003-02/msg00248.html

Tested on sparc-solaris2.7 and sparcv9-solaris2.7 using a multilib
"make check".

Ok for trunk, 3.3 and 3.2 (when it unfreezes) ?

		Thanks,
		--Kaveh


2003-02-05  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>

	* gcc.c-torture/execute/20020227-1.x: Update specific XFAIL
	conditions for SPARC targets.

diff -rup orig/egcc-3.2-CVS20030204/gcc/testsuite/gcc.c-torture/execute/20020227-1.x egcc-3.2-CVS20030204/gcc/testsuite/gcc.c-torture/execute/20020227-1.x
--- orig/egcc-3.2-CVS20030204/gcc/testsuite/gcc.c-torture/execute/20020227-1.x	2002-04-25 14:44:37.000000000 -0400
+++ egcc-3.2-CVS20030204/gcc/testsuite/gcc.c-torture/execute/20020227-1.x	2003-02-05 00:12:51.002181730 -0500
@@ -2,20 +2,32 @@
 # been observed to fail on at least mips-irix6, alpha, ia64, hppa64,
 # sparc64/sparcv9 and mmix during April 2002.
 
-if { [istarget "*64*-*-*"] || [istarget "alpha*-*-*"] || [istarget "mmix-*-*"]
-     || [istarget "sparcv9-*-*"] || [istarget "mips*-*-irix6*"] } {
-    set torture_execute_xfail [istarget]
-}
-
-# Regular sparc- also fails with -m64.
-set torture_eval_before_execute {
-    global compiler_conditional_xfail_data
-    set compiler_conditional_xfail_data {
-        "This test fails on 64-bit targets, see PR6221." \
-        { "sparc-*-*" } \
-        { "-m64" } \
-        { "" }
+if { [istarget "sparc64-*-*"] || [istarget "sparcv9-*-*"] } {
+    # On sparc64/sparcv9 it doesn't fail at -O0/-O1, or at all with -m32.
+    set torture_eval_before_execute {
+        global compiler_conditional_xfail_data
+        set compiler_conditional_xfail_data {
+            "This test fails on 64-bit targets, see PR6221." \
+            { "*-*-*" } \
+            { "-O2" "-O3" "-Os" } \
+            { "-m32" }
+        }
     }
+} elseif { [istarget "sparc-*-*"] } {
+    # Regular sparc fails with -m64, but not with -O0/-O1.
+    set torture_eval_before_execute {
+        global compiler_conditional_xfail_data
+        set compiler_conditional_xfail_data {
+            "This test fails on 64-bit targets, see PR6221." \
+            { "*-*-*" } \
+            { "-m64" } \
+            { "-O0" "-O1" }
+        }
+    }
+} elseif { [istarget "*64*-*-*"] || [istarget "alpha*-*-*"]
+        || [istarget "mmix-*-*"] || [istarget "mips*-*-irix6*"] } {
+    # Other 64-bit targets fail at all optimization levels.
+    set torture_execute_xfail [istarget]
 }
 
 return 0


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]