aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.arch
diff options
context:
space:
mode:
authorPhilippe Waroquiers <philippe.waroquiers@skynet.be>2018-10-25 22:42:58 +0200
committerPhilippe Waroquiers <philippe.waroquiers@skynet.be>2018-10-27 14:47:36 +0200
commitc8ee3f04a66141d5fa930cd77bc53ac0bc17de32 (patch)
treef2c3a88ac11509adebced66c5a7d3dd3ad427557 /gdb/testsuite/gdb.arch
parent82b5e646c22b25862debc68a30d44957a9e5e3d3 (diff)
downloadgdb-c8ee3f04a66141d5fa930cd77bc53ac0bc17de32.zip
gdb-c8ee3f04a66141d5fa930cd77bc53ac0bc17de32.tar.gz
gdb-c8ee3f04a66141d5fa930cd77bc53ac0bc17de32.tar.bz2
Remove a bunch of usages of gdb_suppress_tests in 'runto_main'.
In the 'info -q -t' patch series, I started a new test from gdb.threads/threadapply.exp, that uses an obsolete way to do runto_main. This patch changes all occurrences of runto_main using gdb_suppress_tests to use instead fail+return. Note that there are still about 220 occurrences of gdb_suppress_tests but unclear (to me) if these can be similarly trivially be replaced by a fail+return. Further cleanup can be done in follow-up patches. Tests run on Debian/x86_64. gdb/testsuite/ChangeLog 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be> * gdb.arch/altivec-regs.exp: Do not use gdb_suppress_tests in runto_main, use fail + return instead. gdb.arch/amd64-byte.exp: Likewise. gdb.arch/amd64-dword.exp: Likewise. gdb.arch/amd64-word.exp: Likewise. gdb.arch/e500-abi.exp: Likewise. gdb.arch/e500-regs.exp: Likewise. gdb.arch/gdb1291.exp: Likewise. gdb.arch/gdb1431.exp: Likewise. gdb.arch/i386-avx.exp: Likewise. gdb.arch/i386-byte.exp: Likewise. gdb.arch/i386-prologue.exp: Likewise. gdb.arch/i386-sse.exp: Likewise. gdb.arch/i386-word.exp: Likewise. gdb.arch/iwmmxt-regs.exp: Likewise. gdb.arch/pa-nullify.exp: Likewise. gdb.arch/powerpc-prologue.exp: Likewise. gdb.arch/s390-tdbregs.exp: Likewise. gdb.arch/vsx-regs.exp: Likewise. gdb.asm/asm-source.exp: Likewise. gdb.base/auxv.exp: Likewise. gdb.base/bigcore.exp: Likewise. gdb.base/overlays.exp: Likewise. gdb.base/savedregs.exp: Likewise. gdb.base/setshow.exp: Likewise. gdb.base/sigaltstack.exp: Likewise. gdb.base/sigbpt.exp: Likewise. gdb.base/siginfo-addr.exp: Likewise. gdb.base/siginfo-obj.exp: Likewise. gdb.base/siginfo-thread.exp: Likewise. gdb.base/siginfo.exp: Likewise. gdb.base/signull.exp: Likewise. gdb.base/sigrepeat.exp: Likewise. gdb.base/structs2.exp: Likewise. gdb.threads/threadapply.exp: Likewise. gdb.threads/watchthreads.exp: Likewise. gdb.threads/watchthreads2.exp: Likewise.
Diffstat (limited to 'gdb/testsuite/gdb.arch')
-rw-r--r--gdb/testsuite/gdb.arch/altivec-regs.exp3
-rw-r--r--gdb/testsuite/gdb.arch/amd64-byte.exp3
-rw-r--r--gdb/testsuite/gdb.arch/amd64-dword.exp3
-rw-r--r--gdb/testsuite/gdb.arch/amd64-word.exp3
-rw-r--r--gdb/testsuite/gdb.arch/e500-abi.exp3
-rw-r--r--gdb/testsuite/gdb.arch/e500-regs.exp6
-rw-r--r--gdb/testsuite/gdb.arch/gdb1291.exp3
-rw-r--r--gdb/testsuite/gdb.arch/gdb1431.exp3
-rw-r--r--gdb/testsuite/gdb.arch/i386-avx.exp3
-rw-r--r--gdb/testsuite/gdb.arch/i386-byte.exp3
-rw-r--r--gdb/testsuite/gdb.arch/i386-prologue.exp3
-rw-r--r--gdb/testsuite/gdb.arch/i386-sse.exp3
-rw-r--r--gdb/testsuite/gdb.arch/i386-word.exp3
-rw-r--r--gdb/testsuite/gdb.arch/iwmmxt-regs.exp3
-rw-r--r--gdb/testsuite/gdb.arch/pa-nullify.exp15
-rw-r--r--gdb/testsuite/gdb.arch/powerpc-prologue.exp3
-rw-r--r--gdb/testsuite/gdb.arch/s390-tdbregs.exp5
-rw-r--r--gdb/testsuite/gdb.arch/vsx-regs.exp3
18 files changed, 49 insertions, 22 deletions
diff --git a/gdb/testsuite/gdb.arch/altivec-regs.exp b/gdb/testsuite/gdb.arch/altivec-regs.exp
index fcff886..e481779 100644
--- a/gdb/testsuite/gdb.arch/altivec-regs.exp
+++ b/gdb/testsuite/gdb.arch/altivec-regs.exp
@@ -58,7 +58,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
gdb_test "set print frame-arguments all"
diff --git a/gdb/testsuite/gdb.arch/amd64-byte.exp b/gdb/testsuite/gdb.arch/amd64-byte.exp
index 9f2fbe8..d943342 100644
--- a/gdb/testsuite/gdb.arch/amd64-byte.exp
+++ b/gdb/testsuite/gdb.arch/amd64-byte.exp
@@ -38,7 +38,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
set byte_regs(1) al
diff --git a/gdb/testsuite/gdb.arch/amd64-dword.exp b/gdb/testsuite/gdb.arch/amd64-dword.exp
index ceafed3..2f94ff3 100644
--- a/gdb/testsuite/gdb.arch/amd64-dword.exp
+++ b/gdb/testsuite/gdb.arch/amd64-dword.exp
@@ -38,7 +38,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
set nr_regs 14
diff --git a/gdb/testsuite/gdb.arch/amd64-word.exp b/gdb/testsuite/gdb.arch/amd64-word.exp
index 4387dd3..b40fde4 100644
--- a/gdb/testsuite/gdb.arch/amd64-word.exp
+++ b/gdb/testsuite/gdb.arch/amd64-word.exp
@@ -38,7 +38,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
set nr_regs 14
diff --git a/gdb/testsuite/gdb.arch/e500-abi.exp b/gdb/testsuite/gdb.arch/e500-abi.exp
index ef5f46f..e4f1a3f 100644
--- a/gdb/testsuite/gdb.arch/e500-abi.exp
+++ b/gdb/testsuite/gdb.arch/e500-abi.exp
@@ -46,7 +46,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
gdb_test "b marker" "Breakpoint 2 at.*file.*e500-abi.c, line \[0-9\]+." "break marker"
diff --git a/gdb/testsuite/gdb.arch/e500-regs.exp b/gdb/testsuite/gdb.arch/e500-regs.exp
index 37f9334..d7204b8 100644
--- a/gdb/testsuite/gdb.arch/e500-regs.exp
+++ b/gdb/testsuite/gdb.arch/e500-regs.exp
@@ -45,7 +45,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
# set all the registers integer portions to 1
@@ -145,7 +146,8 @@ gdb_start
gdb_reinitialize_dir $srcdir/$subdir
gdb_load ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
gdb_test "break vector_fun" \
diff --git a/gdb/testsuite/gdb.arch/gdb1291.exp b/gdb/testsuite/gdb.arch/gdb1291.exp
index 39ccf8b..9b12024 100644
--- a/gdb/testsuite/gdb.arch/gdb1291.exp
+++ b/gdb/testsuite/gdb.arch/gdb1291.exp
@@ -47,7 +47,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
gdb_test "b sub1" "Breakpoint 2.*" "set breakpoint"
diff --git a/gdb/testsuite/gdb.arch/gdb1431.exp b/gdb/testsuite/gdb.arch/gdb1431.exp
index 5671864..db3a15e 100644
--- a/gdb/testsuite/gdb.arch/gdb1431.exp
+++ b/gdb/testsuite/gdb.arch/gdb1431.exp
@@ -49,7 +49,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
gdb_test "advance sub1" "hello world\r\n$hex in sub1 \\(\\)" "get to sub1"
diff --git a/gdb/testsuite/gdb.arch/i386-avx.exp b/gdb/testsuite/gdb.arch/i386-avx.exp
index 9c0793f..6e5730a 100644
--- a/gdb/testsuite/gdb.arch/i386-avx.exp
+++ b/gdb/testsuite/gdb.arch/i386-avx.exp
@@ -43,7 +43,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
send_gdb "print have_avx ()\r"
diff --git a/gdb/testsuite/gdb.arch/i386-byte.exp b/gdb/testsuite/gdb.arch/i386-byte.exp
index 3441344..8bbbe2d 100644
--- a/gdb/testsuite/gdb.arch/i386-byte.exp
+++ b/gdb/testsuite/gdb.arch/i386-byte.exp
@@ -38,7 +38,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
set byte_regs(1) al
diff --git a/gdb/testsuite/gdb.arch/i386-prologue.exp b/gdb/testsuite/gdb.arch/i386-prologue.exp
index 6f88e55..949f98a 100644
--- a/gdb/testsuite/gdb.arch/i386-prologue.exp
+++ b/gdb/testsuite/gdb.arch/i386-prologue.exp
@@ -66,7 +66,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
# Testcase for standard prologue.
diff --git a/gdb/testsuite/gdb.arch/i386-sse.exp b/gdb/testsuite/gdb.arch/i386-sse.exp
index c5bc3c9..7167ca1 100644
--- a/gdb/testsuite/gdb.arch/i386-sse.exp
+++ b/gdb/testsuite/gdb.arch/i386-sse.exp
@@ -43,7 +43,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
send_gdb "print have_sse ()\r"
diff --git a/gdb/testsuite/gdb.arch/i386-word.exp b/gdb/testsuite/gdb.arch/i386-word.exp
index 9669ae2..dce0f58 100644
--- a/gdb/testsuite/gdb.arch/i386-word.exp
+++ b/gdb/testsuite/gdb.arch/i386-word.exp
@@ -38,7 +38,8 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list
clean_restart ${binfile}
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
set word_regs(1) ax
diff --git a/gdb/testsuite/gdb.arch/iwmmxt-regs.exp b/gdb/testsuite/gdb.arch/iwmmxt-regs.exp
index a6560b3..74190b2 100644
--- a/gdb/testsuite/gdb.arch/iwmmxt-regs.exp
+++ b/gdb/testsuite/gdb.arch/iwmmxt-regs.exp
@@ -41,7 +41,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
# Set all the registers to arbitrary values.
diff --git a/gdb/testsuite/gdb.arch/pa-nullify.exp b/gdb/testsuite/gdb.arch/pa-nullify.exp
index 1b3a88f..7532ea9 100644
--- a/gdb/testsuite/gdb.arch/pa-nullify.exp
+++ b/gdb/testsuite/gdb.arch/pa-nullify.exp
@@ -88,7 +88,10 @@ proc get_addr_of_sym { sym } {
return $addr
}
-if { ! [ runto_main ] } then { gdb_suppress_tests; }
+if ![runto_main] then {
+ fail "can't run to main"
+ return 0
+}
set foo [get_addr_of_sym "foo"]
set bar [get_addr_of_sym "bar"]
@@ -122,7 +125,10 @@ proc test_core_bt { test } {
}
set test "core at last insn in foo"
-if { ! [ runto_main ] } then { gdb_suppress_tests; }
+if ![runto_main] then {
+ fail "can't run to main"
+ return 0
+}
gdb_breakpoint "*$foo_last"
gdb_test "continue" "Breakpoint \[0-9\]*,.* in foo.*" "$test: continue to breakpoint"
if [gen_core $test] {
@@ -130,7 +136,10 @@ if [gen_core $test] {
}
set test "core at nullified insn"
-if { ! [ runto_main ] } then { gdb_suppress_tests; }
+if ![runto_main] then {
+ fail "can't run to main"
+ return 0
+}
gdb_breakpoint "*$foo_last"
gdb_test "continue" "Breakpoint \[0-9\]*,.* in foo.*" "$test: continue to breakpoint"
gdb_test "stepi" ".*in foo.*" "$test: step to nullified instruction"
diff --git a/gdb/testsuite/gdb.arch/powerpc-prologue.exp b/gdb/testsuite/gdb.arch/powerpc-prologue.exp
index 5251dfa..eef1f7b 100644
--- a/gdb/testsuite/gdb.arch/powerpc-prologue.exp
+++ b/gdb/testsuite/gdb.arch/powerpc-prologue.exp
@@ -44,7 +44,8 @@ gdb_load ${binfile}
#
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
# Testcase for PIC prologue.
diff --git a/gdb/testsuite/gdb.arch/s390-tdbregs.exp b/gdb/testsuite/gdb.arch/s390-tdbregs.exp
index e454feb..f5d1513 100644
--- a/gdb/testsuite/gdb.arch/s390-tdbregs.exp
+++ b/gdb/testsuite/gdb.arch/s390-tdbregs.exp
@@ -35,8 +35,9 @@ if { [prepare_for_testing "failed to prepare" $testfile $srcfile \
return -1
}
-if { ![runto_main] } then {
- gdb_suppress_tests
+if ![runto_main] then {
+ fail "can't run to main"
+ return 0
}
gdb_test_multiple "next" "check for TE support" {
diff --git a/gdb/testsuite/gdb.arch/vsx-regs.exp b/gdb/testsuite/gdb.arch/vsx-regs.exp
index e4f674a..ca6e776 100644
--- a/gdb/testsuite/gdb.arch/vsx-regs.exp
+++ b/gdb/testsuite/gdb.arch/vsx-regs.exp
@@ -53,7 +53,8 @@ gdb_load ${binfile}
# Run to `main' where we begin our tests.
if ![runto_main] then {
- gdb_suppress_tests
+ fail "can't run to main"
+ return 0
}
set endianness [get_endianness]