[binutils-gdb] [gdb/testsuite] Fix timeout in gdb.base/valgrind-infcall-2.exp

Tom de Vries vries@sourceware.org
Thu Apr 29 21:32:23 GMT 2021


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=3f334074870230900da2ddec0556c9b4a6d55249

commit 3f334074870230900da2ddec0556c9b4a6d55249
Author: Tom de Vries <tdevries@suse.de>
Date:   Thu Apr 29 23:32:20 2021 +0200

    [gdb/testsuite] Fix timeout in gdb.base/valgrind-infcall-2.exp
    
    Since commit 6d5702a5eb3 "Fix test case gdb.base/valgrind-bt.exp" I run into:
    ...
    FAIL: gdb.base/valgrind-infcall-2.exp: target remote for vgdb (timeout)
    FAIL: gdb.base/valgrind-infcall-2.exp: monitor v.set gdb_output (timeout)
    ...
    
    The commit adds this line in proc vgdb_start:
    ...
        set vgdbcmd "set remotetimeout 3"
    ...
    which has no effect given that the value of var vgdbcmd is not used before
    it's overwritten.  We can fix this by doing instead:
    ...
        set_remotetimeout 3
    ...
    
    The FAIL I'm observing is fixed by increasing the remotetimeout value to 4.
    
    Tested on x86_64-linux.
    
    gdb/testsuite/ChangeLog:
    
    2021-04-29  Tom de Vries  <tdevries@suse.de>
    
            PR testsuite/27786
            * lib/valgrind.exp (vgdb_start): Use set_remotetimeout.  Increase
            remotetimeout to 4.

Diff:
---
 gdb/testsuite/ChangeLog        | 6 ++++++
 gdb/testsuite/lib/valgrind.exp | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index d4ed915881b..42ffb651f28 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,9 @@
+2021-04-29  Tom de Vries  <tdevries@suse.de>
+
+	PR testsuite/27786
+	* lib/valgrind.exp (vgdb_start): Use set_remotetimeout.  Increase
+	remotetimeout to 4.
+
 2021-04-28  Tom Tromey  <tromey@adacore.com>
 
 	* gdb.ada/null_overload.exp: New file.
diff --git a/gdb/testsuite/lib/valgrind.exp b/gdb/testsuite/lib/valgrind.exp
index caabeda9730..bba338f880c 100644
--- a/gdb/testsuite/lib/valgrind.exp
+++ b/gdb/testsuite/lib/valgrind.exp
@@ -82,7 +82,7 @@ proc vgdb_start { {active_at_startup 1} } {
 
     clean_restart $testfile
 
-    set vgdbcmd "set remotetimeout 3"
+    set_remotetimeout 4
 
     # Make sure we're disconnected, in case we're testing with the
     # native-extended-gdbserver board, where gdb_start/gdb_load spawn


More information about the Gdb-cvs mailing list