aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>2011-06-07 16:43:29 +0000
committerRainer Orth <ro@gcc.gnu.org>2011-06-07 16:43:29 +0000
commit91ffe356293c90378b8deb7e82262ade077f29dc (patch)
tree7d8032282651d425299a86fe5c74b6c418d19d65
parent16d80e03f9e9742e929ed65e98189c2e59ca9aa0 (diff)
downloadgcc-91ffe356293c90378b8deb7e82262ade077f29dc.zip
gcc-91ffe356293c90378b8deb7e82262ade077f29dc.tar.gz
gcc-91ffe356293c90378b8deb7e82262ade077f29dc.tar.bz2
re PR tree-optimization/48497 (gfortran.dg/graphite/vect-pr40979.f90 FAILs without -march=pentium4)
gcc: PR tree-optimization/48497 * doc/sourcebuild.texi (Directives, dg-additional-options): Document. gcc/testsuite: PR tree-optimization/48497 * lib/gcc-defs.exp (dg-additional-options): New proc. * gfortran.dg/graphite/vect-pr40979.f90: Use dg-additional-options -msse2 on 32-bit x86. From-SVN: r174759
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/doc/sourcebuild.texi5
-rw-r--r--gcc/testsuite/ChangeLog8
-rw-r--r--gcc/testsuite/gfortran.dg/graphite/vect-pr40979.f901
-rw-r--r--gcc/testsuite/lib/gcc-defs.exp22
5 files changed, 41 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 932e8e1d..1986a88 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2011-06-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ PR tree-optimization/48497
+ * doc/sourcebuild.texi (Directives, dg-additional-options): Document.
+
2011-06-07 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
PR tree-optimization/46728
diff --git a/gcc/doc/sourcebuild.texi b/gcc/doc/sourcebuild.texi
index 1e02809..64210c2 100644
--- a/gcc/doc/sourcebuild.texi
+++ b/gcc/doc/sourcebuild.texi
@@ -1016,6 +1016,11 @@ This directive does nothing on targets that enable the features by
default, or that don't provide them at all. It must come after
all @code{dg-options} directives.
For supported values of @var{feature} see @ref{Add Options, ,}.
+
+@item @{ dg-additional-options @var{options} [@{ target @var{selector} @}] @}
+This directive provides a list of compiler options, to be used
+if the target system matches @var{selector}, that are added to the default
+options used for this set of tests.
@end table
@subsubsection Modify the test timeout value
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index b38cd1e..1372638 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2011-06-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ gcc/testsuite:
+ PR tree-optimization/48497
+ * lib/gcc-defs.exp (dg-additional-options): New proc.
+ * gfortran.dg/graphite/vect-pr40979.f90: Use dg-additional-options
+ -msse2 on 32-bit x86.
+
2011-06-06 Jason Merrill <jason@redhat.com>
* g++.dg/cpp0x/enum19.C: New.
diff --git a/gcc/testsuite/gfortran.dg/graphite/vect-pr40979.f90 b/gcc/testsuite/gfortran.dg/graphite/vect-pr40979.f90
index 662b82a..f620d0c 100644
--- a/gcc/testsuite/gfortran.dg/graphite/vect-pr40979.f90
+++ b/gcc/testsuite/gfortran.dg/graphite/vect-pr40979.f90
@@ -1,5 +1,6 @@
! { dg-do compile }
! { dg-require-effective-target vect_double }
+! { dg-additional-options "-msse2" { target { { i?86-*-* x86_64-*-* } && ilp32 } } }
module mqc_m
integer, parameter, private :: longreal = selected_real_kind(15,90)
diff --git a/gcc/testsuite/lib/gcc-defs.exp b/gcc/testsuite/lib/gcc-defs.exp
index ed8c041..f48520e 100644
--- a/gcc/testsuite/lib/gcc-defs.exp
+++ b/gcc/testsuite/lib/gcc-defs.exp
@@ -183,6 +183,28 @@ if { [info procs runtest_file_p] == "" } then {
}
}
+# Like dg-options, but adds to the default options rather than replacing them.
+
+proc dg-additional-options { args } {
+ upvar dg-extra-tool-flags extra-tool-flags
+
+ if { [llength $args] > 3 } {
+ error "[lindex $args 0]: too many arguments"
+ return
+ }
+
+ if { [llength $args] >= 3 } {
+ switch [dg-process-target [lindex $args 2]] {
+ "S" { eval lappend extra-tool-flags [lindex $args 1] }
+ "N" { }
+ "F" { error "[lindex $args 0]: `xfail' not allowed here" }
+ "P" { error "[lindex $args 0]: `xfail' not allowed here" }
+ }
+ } else {
+ eval lappend extra-tool-flags [lindex $args 1]
+ }
+}
+
# Record additional sources files that must be compiled along with the
# main source file.