From: Tom de Vries <tdevries@suse.de>
To: gdb-patches@sourceware.org
Subject: [committed][gdb/testsuite] Fix timeouts with -readnow
Date: Tue, 28 Apr 2020 11:32:00 +0200 [thread overview]
Message-ID: <20200428093158.GA12103@delia> (raw)
Hi,
With target board readnow, I run into timeouts for test cases
gdb.base/multi-forks.exp and gdb.threads/fork-plus-threads.exp.
Fix these using with_timeout_factor.
Tested on x86_64-linux.
Committed to trunk.
Thanks,
- Tom
[gdb/testsuite] Fix timeouts with -readnow
gdb/testsuite/ChangeLog:
2020-04-28 Tom de Vries <tdevries@suse.de>
* gdb.base/multi-forks.exp: Use with_timeout_factor.
* gdb.threads/fork-plus-threads.exp: Same.
---
gdb/testsuite/gdb.base/multi-forks.exp | 5 ++-
gdb/testsuite/gdb.threads/fork-plus-threads.exp | 41 +++++++++++++------------
2 files changed, 26 insertions(+), 20 deletions(-)
diff --git a/gdb/testsuite/gdb.base/multi-forks.exp b/gdb/testsuite/gdb.base/multi-forks.exp
index 59d953b04d6..0d75d0c153c 100644
--- a/gdb/testsuite/gdb.base/multi-forks.exp
+++ b/gdb/testsuite/gdb.base/multi-forks.exp
@@ -149,7 +149,10 @@ gdb_test_no_output "set detach off" "set detach off"
#
for {set i 1} {$i <= 15} {incr i} {
- gdb_test "continue" "Breakpoint .* main .*exit.*" "run to exit $i"
+ # Fix timeouts with -readnow.
+ with_timeout_factor 3 {
+ gdb_test "continue" "Breakpoint .* main .*exit.*" "run to exit $i"
+ }
gdb_test "info inferior" " 2 .* 3 .* 4 .* 5 .*" "info inferior $i"
gdb_test "inferior $i + 1" "(_dl_sysinfo_int80|fork|__kernel_(v|)syscall).*" \
"inferior $i"
diff --git a/gdb/testsuite/gdb.threads/fork-plus-threads.exp b/gdb/testsuite/gdb.threads/fork-plus-threads.exp
index 8d36b96810b..91453329c26 100644
--- a/gdb/testsuite/gdb.threads/fork-plus-threads.exp
+++ b/gdb/testsuite/gdb.threads/fork-plus-threads.exp
@@ -78,25 +78,28 @@ proc do_test { detach_on_fork } {
set saw_thread_stopped 0
set test "inferior 1 exited"
- gdb_test_multiple "" $test {
- -re "Cannot remove breakpoints" {
- set saw_cannot_remove_breakpoints 1
- exp_continue
- }
- -re "Thread \[^\r\n\]+ stopped\\." {
- set saw_thread_stopped 1
- exp_continue
- }
- -re "Thread \[^\r\n\]+ exited" {
- # Avoid timeout with check-read1
- exp_continue
- }
- -re "New Thread \[^\r\n\]+" {
- # Avoid timeout with check-read1
- exp_continue
- }
- -re "Inferior 1 \(\[^\r\n\]+\) exited normally" {
- pass $test
+ # Fix timeouts with -readnow.
+ with_timeout_factor 3 {
+ gdb_test_multiple "" $test {
+ -re "Cannot remove breakpoints" {
+ set saw_cannot_remove_breakpoints 1
+ exp_continue
+ }
+ -re "Thread \[^\r\n\]+ stopped\\." {
+ set saw_thread_stopped 1
+ exp_continue
+ }
+ -re "Thread \[^\r\n\]+ exited" {
+ # Avoid timeout with check-read1
+ exp_continue
+ }
+ -re "New Thread \[^\r\n\]+" {
+ # Avoid timeout with check-read1
+ exp_continue
+ }
+ -re "Inferior 1 \(\[^\r\n\]+\) exited normally" {
+ pass $test
+ }
}
}
reply other threads:[~2020-04-28 9:32 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200428093158.GA12103@delia \
--to=tdevries@suse.de \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox