diff options
author | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-05-27 18:57:10 +0000 |
---|---|---|
committer | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-05-27 18:57:10 +0000 |
commit | ed0a1f3113cc3e1a81a085576c1806bdb70b0f8d (patch) | |
tree | 85583dd10e025d8214565b0252caef2a519217ee /gcc/testsuite | |
parent | a3f1492363ddf83826552ab4de9265906a92b6d2 (diff) | |
download | gcc-ed0a1f3113cc3e1a81a085576c1806bdb70b0f8d.tar.gz |
gcc/testsuite/
* lib/fortran-torture.exp (get-fortran-torture-options):
New function, replacing old FORTRAN_TORTURE_OPTIONS code.
* gfortran.fortran-torture/compile/compile.exp: Use
[get-fortran-torture-options] instead of $FORTRAN_TORTURE_OPTIONS.
* gfortran.fortran-torture/execute/execute.exp: Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@136050 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite')
-rw-r--r-- | gcc/testsuite/ChangeLog | 8 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.fortran-torture/compile/compile.exp | 2 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.fortran-torture/execute/execute.exp | 2 | ||||
-rw-r--r-- | gcc/testsuite/lib/fortran-torture.exp | 25 |
4 files changed, 27 insertions, 10 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index ec36b2c52f1..b94e9d92f9c 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2008-05-27 Richard Sandiford <rdsandiford@googlemail.com> + + * lib/fortran-torture.exp (get-fortran-torture-options): + New function, replacing old FORTRAN_TORTURE_OPTIONS code. + * gfortran.fortran-torture/compile/compile.exp: Use + [get-fortran-torture-options] instead of $FORTRAN_TORTURE_OPTIONS. + * gfortran.fortran-torture/execute/execute.exp: Likewise. + 2008-05-27 Michael Matz <matz@suse.de> PR c++/27975 diff --git a/gcc/testsuite/gfortran.fortran-torture/compile/compile.exp b/gcc/testsuite/gfortran.fortran-torture/compile/compile.exp index b18e25c5f6f..6c4890d7b72 100644 --- a/gcc/testsuite/gfortran.fortran-torture/compile/compile.exp +++ b/gcc/testsuite/gfortran.fortran-torture/compile/compile.exp @@ -26,7 +26,7 @@ load_lib fortran-torture.exp load_lib torture-options.exp torture-init -set-torture-options $FORTRAN_TORTURE_OPTIONS +set-torture-options [get-fortran-torture-options] foreach testcase [lsort [glob -nocomplain $srcdir/$subdir/*.f]] { # If we're only testing specific files and this isn't one of them, skip it. diff --git a/gcc/testsuite/gfortran.fortran-torture/execute/execute.exp b/gcc/testsuite/gfortran.fortran-torture/execute/execute.exp index 157c2404601..2dd408df2d6 100644 --- a/gcc/testsuite/gfortran.fortran-torture/execute/execute.exp +++ b/gcc/testsuite/gfortran.fortran-torture/execute/execute.exp @@ -30,7 +30,7 @@ load_lib fortran-torture.exp load_lib torture-options.exp torture-init -set-torture-options $FORTRAN_TORTURE_OPTIONS +set-torture-options [get-fortran-torture-options] foreach testcase [lsort [glob -nocomplain $srcdir/$subdir/*.f]] { # If we're only testing specific files and this isn't one of them, skip it. diff --git a/gcc/testsuite/lib/fortran-torture.exp b/gcc/testsuite/lib/fortran-torture.exp index 3286ad91e8a..6e49fac834c 100644 --- a/gcc/testsuite/lib/fortran-torture.exp +++ b/gcc/testsuite/lib/fortran-torture.exp @@ -22,12 +22,16 @@ load_lib target-supports.exp +# Return the list of options to use for fortran torture tests. # The default option list can be overridden by # TORTURE_OPTIONS="{ { list1 } ... { listN } }" +proc get-fortran-torture-options { } { + global TORTURE_OPTIONS + + if [info exists TORTURE_OPTIONS] { + return $TORTURE_OPTIONS + } -if [info exists TORTURE_OPTIONS] { - set FORTRAN_TORTURE_OPTIONS $TORTURE_OPTIONS -} else { # determine if host supports vectorization, and the necessary set # of options, based on code from testsuite/vect/vect.exp @@ -61,17 +65,22 @@ if [info exists TORTURE_OPTIONS] { set test_tree_vectorize 0 } - set FORTRAN_TORTURE_OPTIONS [list \ - { -O0 } { -O1 } { -O2 } \ + set options {} + + lappend options \ + { -O0 } \ + { -O1 } \ + { -O2 } \ { -O2 -fomit-frame-pointer -finline-functions } \ { -O2 -fomit-frame-pointer -finline-functions -funroll-loops } \ { -O2 -fbounds-check } \ { -O3 -g } \ - { -Os }] - + { -Os } if { $test_tree_vectorize } { - lappend FORTRAN_TORTURE_OPTIONS $vectorizer_options + lappend options $vectorizer_options } + + return $options } |