aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorH.J. Lu <hjl@gcc.gnu.org>2009-11-11 12:34:13 -0800
committerH.J. Lu <hjl@gcc.gnu.org>2009-11-11 12:34:13 -0800
commit5fae76b1004f5f6d195b000d5866703a4d2faf91 (patch)
treea060b88ae1942c97f5cb8f08cd42d53acf451025 /gcc
parenta4ecd144bb7cbad8f122f98b2db8a3b6de468361 (diff)
downloadgcc-5fae76b1004f5f6d195b000d5866703a4d2faf91.zip
gcc-5fae76b1004f5f6d195b000d5866703a4d2faf91.tar.gz
gcc-5fae76b1004f5f6d195b000d5866703a4d2faf91.tar.bz2
re PR testsuite/42001 (LTO tests fail with non multilib targets (but still not --disable-multilib ))
2009-11-11 H.J. Lu <hongjiu.lu@intel.com> PR testsuite/42001 * gcc.dg/lto/lto.exp: Pass no-mathlib to lto_init. Call lto_finish at the end. * lib/lto.exp (lto_init): Set mathlib to " " for no-mathlib. (lto_finish): New. Restore mathlib. From-SVN: r154104
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/ChangeLog19
-rw-r--r--gcc/testsuite/gcc.dg/lto/lto.exp4
-rw-r--r--gcc/testsuite/lib/lto.exp29
3 files changed, 45 insertions, 7 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 16340e5..c0a802e 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,12 @@
+2009-11-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR testsuite/42001
+ * gcc.dg/lto/lto.exp: Pass no-mathlib to lto_init. Call
+ lto_finish at the end.
+
+ * lib/lto.exp (lto_init): Set mathlib to " " for no-mathlib.
+ (lto_finish): New. Restore mathlib.
+
2009-11-11 Kai Tietz <kai.tietz@onevision.com>
* g++.dg/torture/pushpop_macro.C: New testcase.
@@ -7,11 +16,11 @@
2009-11-11 Jon Beniston <jon@beniston.com>
- * lib/target-supports.exp (check_profiling_available): lm32 target
- doesn't support profiling.
- * gcc.dg/20020312-2.c: Add lm32 support.
- * g++.dg/other/packed1.C: Expect to fail on lm32.
- * g++.old-deja/g++.jason/thunk3.C: Likewise.
+ * lib/target-supports.exp (check_profiling_available): lm32 target
+ doesn't support profiling.
+ * gcc.dg/20020312-2.c: Add lm32 support.
+ * g++.dg/other/packed1.C: Expect to fail on lm32.
+ * g++.old-deja/g++.jason/thunk3.C: Likewise.
2009-11-11 Daniel Jacobowitz <dan@codesourcery.com>
diff --git a/gcc/testsuite/gcc.dg/lto/lto.exp b/gcc/testsuite/gcc.dg/lto/lto.exp
index 0e343c1..6cd798f 100644
--- a/gcc/testsuite/gcc.dg/lto/lto.exp
+++ b/gcc/testsuite/gcc.dg/lto/lto.exp
@@ -35,7 +35,7 @@ load_lib gcc.exp
load_lib lto.exp
gcc_init
-lto_init
+lto_init no-mathlib
# Define an identifier for use with this suite to avoid name conflicts
# with other lto tests running at the same time.
@@ -55,3 +55,5 @@ foreach src [lsort [find $srcdir/$subdir *_0.c]] {
lto-execute $src $sid
}
+
+lto_finish
diff --git a/gcc/testsuite/lib/lto.exp b/gcc/testsuite/lib/lto.exp
index cccd642..c3ff61a 100644
--- a/gcc/testsuite/lib/lto.exp
+++ b/gcc/testsuite/lib/lto.exp
@@ -17,11 +17,22 @@
# Contributed by Diego Novillo <dnovillo@google.com>
-# lto_init -- called at the start of eac subdir of tests
+# lto_init -- called at the start of each subdir of tests
proc lto_init { args } {
global LTO_OPTIONS
+ if {[info exists args] && $args == "no-mathlib"} {
+ global board_info
+ global saved_mathlib
+
+ set dest [target_info name]
+ if [board_info $dest exists mathlib] {
+ set saved_mathlib [board_info $dest mathlib]
+ }
+ set board_info($dest,mathlib) " "
+ }
+
# Each test is run with the compiler options from this list.
# The default option lists can be overridden by LTO_OPTIONS="[list
# {opts_1} {opts_2}... {opts_n}]" where opts_i are lists of options.
@@ -37,6 +48,22 @@ proc lto_init { args } {
}
}
+#
+# lto_finish -- called at the end of each subdir of tests if mathlib is
+# changed.
+#
+
+proc lto_finish { } {
+ global board_info
+ global saved_mathlib
+
+ set dest [target_info name]
+ if [info exists saved_mathlib] {
+ set board_info($dest,mathlib) $saved_mathlib
+ } elseif [board_info $dest exists mathlib] {
+ unset board_info($dest,mathlib)
+ }
+}
# Subsets of tests can be selectively disabled by members of this list:
# - ATTRIBUTE: disable all tests using the __attribute__ extension,