Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Sandra Loosemore <sandra@codesourcery.com>
To: gdb-patches <gdb-patches@sourceware.org>
Subject: [patch, testsuite] adjust timeout in gdb.base/freebpcmd.exp
Date: Wed, 21 Oct 2015 19:41:00 -0000	[thread overview]
Message-ID: <5627B95B.9040907@codesourcery.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 450 bytes --]

I've been observing random failures in gdb.base/freebpcmd.exp on a 
bare-metal target using RSP with a slow debug probe.  It seems that the 
hardwired timeout of 120 seconds for this test is just a little too low 
for this target.  It seems better to use with_timeout_factor instead of 
a hardwired value; choosing a factor of 10 here is totally random, but 
it seems to be plenty on this target (its default timeout is 60).

OK to commit?

-Sandra


[-- Attachment #2: gdb-freebpcmd.log --]
[-- Type: text/x-log, Size: 162 bytes --]

2015-10-21  Sandra Loosemore  <sandra@codesourcery.com>

	gdb/testsuite/
	* gdb.base/freebpcmd.exp: Use with_timeout_factor instead
	of hardwired timeout value.


[-- Attachment #3: gdb-freebpcmd.patch --]
[-- Type: text/x-patch, Size: 1359 bytes --]

diff --git a/gdb/testsuite/gdb.base/freebpcmd.exp b/gdb/testsuite/gdb.base/freebpcmd.exp
index 2f46bc8..c7c0814 100644
--- a/gdb/testsuite/gdb.base/freebpcmd.exp
+++ b/gdb/testsuite/gdb.base/freebpcmd.exp
@@ -103,22 +103,19 @@ if {$i >= [llength $lines]} {
 
 gdb_run_cmd
 
-set prev_timeout $timeout
-set timeout 120
-
-gdb_test_multiple "" "run program with breakpoint commands" {
-    -re "warning: Invalid control type in command structure" {
-        kfail "gdb/1489" "run program with breakpoint commands"
-    }
-    -re "Invalid i value\r\n$gdb_prompt $" {
-	xfail "run program with breakpoint commands (i value not readable)"
-    }
-    -re "$gdb_prompt $" {
-        pass "run program with breakpoint commands"
-    }
-    eof {
-        kfail "gdb/1489" "run program with breakpoint commands (GDB died)"
+with_timeout_factor 10 {
+    gdb_test_multiple "" "run program with breakpoint commands" {
+	-re "warning: Invalid control type in command structure" {
+	    kfail "gdb/1489" "run program with breakpoint commands"
+	}
+	-re "Invalid i value\r\n$gdb_prompt $" {
+	    xfail "run program with breakpoint commands (i value not readable)"
+	}
+	-re "$gdb_prompt $" {
+	    pass "run program with breakpoint commands"
+	}
+	eof {
+	    kfail "gdb/1489" "run program with breakpoint commands (GDB died)"
+	}
     }
 }
-
-set timeout $prev_timeout

             reply	other threads:[~2015-10-21 16:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-21 19:41 Sandra Loosemore [this message]
2015-10-21 19:42 ` Yao Qi

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=5627B95B.9040907@codesourcery.com \
    --to=sandra@codesourcery.com \
    --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