* [lto] Fix botched -flto flags in testsuite
@ 2008-10-16 15:09 Diego Novillo
0 siblings, 0 replies; only message in thread
From: Diego Novillo @ 2008-10-16 15:09 UTC (permalink / raw)
To: gcc-patches
Thanks to Rafael for noticing this. When I added -flto to the
testsuite I didn't look close enough at the new failures.
Some of them were failing for the obvious reason that the flags
were being passed incorrectly. This patch fixes that.
Tested on x86_64. This time I did check for the obvious.
Diego.
* gcc.dg/debug/debug.exp: Fix -flto options
* gcc.dg/vect/costmodel/ppc/ppc-costmodel-vect.exp: Likewise.
* gcc.dg/vect/costmodel/spu/spu-costmodel-vect.exp: Likewise.
* gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp: Likewise.
* gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp: Likewise.
* gcc.dg/vect/vect.exp: Likewise.
* gcc.misc-tests/dectest.exp: Likewise.
* g++.dg/debug/debug.exp: Likewise.
* g++.dg/vect/vect.exp: Likewise.
Index: testsuite/gcc.dg/debug/debug.exp
===================================================================
--- testsuite/gcc.dg/debug/debug.exp (revision 141168)
+++ testsuite/gcc.dg/debug/debug.exp (working copy)
@@ -24,7 +24,7 @@ dg-init
# Main loop.
-gcc-dg-debug-runtest gcc_target_compile trivial.c [list "-O -flto" "-O3 -flto"] \
+gcc-dg-debug-runtest gcc_target_compile trivial.c [list -O -O3 -flto] \
[lsort [glob -nocomplain $srcdir/$subdir/*.\[cS\]]]
# All done.
Index: testsuite/gcc.dg/vect/costmodel/ppc/ppc-costmodel-vect.exp
===================================================================
--- testsuite/gcc.dg/vect/costmodel/ppc/ppc-costmodel-vect.exp (revision 141168)
+++ testsuite/gcc.dg/vect/costmodel/ppc/ppc-costmodel-vect.exp (working copy)
@@ -33,7 +33,7 @@ if ![is-effective-target powerpc_altivec
set DEFAULT_VECTCFLAGS ""
# These flags are used for all targets.
-lappend DEFAULT_VECTCFLAGS "-O2 -flto" "-ftree-vectorize" "-fvect-cost-model"
+lappend DEFAULT_VECTCFLAGS "-O2" "-flto" "-ftree-vectorize" "-fvect-cost-model"
# If the target system supports vector instructions, the default action
# for a test is 'run', otherwise it's 'compile'. Save current default.
Index: testsuite/gcc.dg/vect/costmodel/spu/spu-costmodel-vect.exp
===================================================================
--- testsuite/gcc.dg/vect/costmodel/spu/spu-costmodel-vect.exp (revision 141168)
+++ testsuite/gcc.dg/vect/costmodel/spu/spu-costmodel-vect.exp (working copy)
@@ -29,7 +29,7 @@ if { ![istarget spu*-*-*] } then {
set DEFAULT_VECTCFLAGS ""
# These flags are used for all targets.
-lappend DEFAULT_VECTCFLAGS "-O2 -flto" "-ftree-vectorize" "-fvect-cost-model"
+lappend DEFAULT_VECTCFLAGS "-O2" "-flto" "-ftree-vectorize" "-fvect-cost-model"
# If the target system supports vector instructions, the default action
# for a test is 'run', otherwise it's 'compile'. Save current default.
Index: testsuite/gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp
===================================================================
--- testsuite/gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp (revision 141168)
+++ testsuite/gcc.dg/vect/costmodel/i386/i386-costmodel-vect.exp (working copy)
@@ -28,7 +28,7 @@ if { ![istarget i?86*-*-*] && ![istarget
set DEFAULT_VECTCFLAGS ""
# These flags are used for all targets.
-lappend DEFAULT_VECTCFLAGS "-O2 -flto" "-ftree-vectorize" "-fvect-cost-model"
+lappend DEFAULT_VECTCFLAGS "-O2" "-flto" "-ftree-vectorize" "-fvect-cost-model"
# If the target system supports vector instructions, the default action
# for a test is 'run', otherwise it's 'compile'. Save current default.
Index: testsuite/gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp
===================================================================
--- testsuite/gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp (revision 141168)
+++ testsuite/gcc.dg/vect/costmodel/x86_64/x86_64-costmodel-vect.exp (working copy)
@@ -29,7 +29,7 @@ if { (![istarget x86_64-*-*] && ![istarg
set DEFAULT_VECTCFLAGS ""
# These flags are used for all targets.
-lappend DEFAULT_VECTCFLAGS "-O2 -flto" "-ftree-vectorize" "-fvect-cost-model"
+lappend DEFAULT_VECTCFLAGS "-O2" "-flto" "-ftree-vectorize" "-fvect-cost-model"
# If the target system supports vector instructions, the default action
# for a test is 'run', otherwise it's 'compile'. Save current default.
Index: testsuite/gcc.dg/vect/vect.exp
===================================================================
--- testsuite/gcc.dg/vect/vect.exp (revision 141168)
+++ testsuite/gcc.dg/vect/vect.exp (working copy)
@@ -111,10 +111,12 @@ dg-init
global O1_VECTCFLAGS
set O1_VECTCFLAGS $DEFAULT_VECTCFLAGS
-lappend O1_VECTCFLAGS "-O1 -flto"
+lappend O1_VECTCFLAGS "-O1"
+lappend O1_VECTCFLAGS "-flto"
lappend O1_VECTCFLAGS "-fdump-tree-vect-details"
-lappend DEFAULT_VECTCFLAGS "-O2 -flto"
+lappend DEFAULT_VECTCFLAGS "-O2"
+lappend DEFAULT_VECTCFLAGS "-flto"
# Tests that should be run without generating dump info
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/nodump-*.\[cS\]]] \
@@ -238,13 +240,15 @@ dg-runtest [lsort [glob -nocomplain $src
# With -Os
set DEFAULT_VECTCFLAGS $SAVED_DEFAULT_VECTCFLAGS
-lappend DEFAULT_VECTCFLAGS "-Os -flto"
+lappend DEFAULT_VECTCFLAGS "-Os"
+lappend DEFAULT_VECTCFLAGS "-flto"
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/Os-vect-*.\[cS\]]] \
"" $DEFAULT_VECTCFLAGS
# With -O3
set DEFAULT_VECTCFLAGS $SAVED_DEFAULT_VECTCFLAGS
-lappend DEFAULT_VECTCFLAGS "-O3 -flto"
+lappend DEFAULT_VECTCFLAGS "-O3"
+lappend DEFAULT_VECTCFLAGS "-flto"
if [istarget "spu-*-*"] {
lappend DEFAULT_VECTCFLAGS "-funroll-loops"
}
Index: testsuite/gcc.misc-tests/dectest.exp
===================================================================
--- testsuite/gcc.misc-tests/dectest.exp (revision 141168)
+++ testsuite/gcc.misc-tests/dectest.exp (working copy)
@@ -20,7 +20,7 @@
#
# Contributed by Ben Elliston <bje@au.ibm.com>.
-set DEC_TORTURE_OPTIONS [list {} -O1 "-O2 -flto" -O3 -Os -msoft-float]
+set DEC_TORTURE_OPTIONS [list {} -O1 {-O2 -flto} -O3 -Os -msoft-float]
proc target-specific-flags {} {
set result "-frounding-math "
Index: testsuite/g++.dg/debug/debug.exp
===================================================================
--- testsuite/g++.dg/debug/debug.exp (revision 141168)
+++ testsuite/g++.dg/debug/debug.exp (working copy)
@@ -23,7 +23,7 @@ load_lib g++-dg.exp
dg-init
# Main loop.
-gcc-dg-debug-runtest g++_target_compile trivial.C [list "-O2 -flto" "-O3 -flto"] \
+gcc-dg-debug-runtest g++_target_compile trivial.C [list -O2 -O3 -flto] \
[lsort [glob -nocomplain $srcdir/$subdir/*.C]]
# All done.
Index: testsuite/g++.dg/vect/vect.exp
===================================================================
--- testsuite/g++.dg/vect/vect.exp (revision 141168)
+++ testsuite/g++.dg/vect/vect.exp (working copy)
@@ -39,8 +39,8 @@ set save-dg-do-what-default ${dg-do-what
set DEFAULT_VECTCFLAGS ""
# These flags are used for all targets.
-lappend DEFAULT_VECTCFLAGS "-O2 -flto" "-ftree-vectorize" "-fno-vect-cost-model" \
- "-ftree-vectorizer-verbose=4" "-fdump-tree-vect-stats"
+lappend DEFAULT_VECTCFLAGS "-O2" "-flto" "-ftree-vectorize" \
+ "-fno-vect-cost-model" "-ftree-vectorizer-verbose=4" "-fdump-tree-vect-stats"
# Skip these tests for targets that do not support generating vector
# code. Set additional target-dependent vector flags, which can be
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-10-16 13:59 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-10-16 15:09 [lto] Fix botched -flto flags in testsuite Diego Novillo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).