From 0a5d52f0ec8dd56b7953764a9bc1dc71ff6b69ca Mon Sep 17 00:00:00 2001 From: Yao Qi Date: Fri, 22 Apr 2016 17:23:23 +0100 Subject: [PATCH] Fix fails in gdb.trace/unavailable.exp I am seeing some test fails in gdb.trace/unavailable.exp on aarch64-linux, like this, print derived_whole^M $43 = (Derived) { = { = {x = 2}, _vptr.Middle = 0x401860 , y = 3}, _vptr.Derived = 0x401848 , z = 4}^M (gdb) FAIL: gdb.trace/unavailable.exp: collect globals: print object on: print derived_whole print derived_whole^M $47 = { = { = {x = 2}, _vptr.Middle = 0x401860 , y = 3}, _vptr.Derived = 0x401848 , z = 4}^M (gdb) FAIL: gdb.trace/unavailable.exp: collect globals: print object off: print derived_whole these fails are also found by recent x86_64-linux buildbot, https://sourceware.org/ml/gdb-testers/2016-q2/msg00622.html The fix is exactly the same as this one http://www.sourceware.org/ml/gdb-patches/2015-10/msg00252.html (the extra "VTT" after hex), in which we match extra things after $hex. gdb/testsuite: 2016-04-22 Yao Qi * gdb.trace/unavailable.exp (gdb_collect_globals_test_1): Match more after $hex. --- gdb/testsuite/ChangeLog | 5 +++++ gdb/testsuite/gdb.trace/unavailable.exp | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index e49220e08aa..c7c9d58416b 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2016-04-22 Yao Qi + + * gdb.trace/unavailable.exp (gdb_collect_globals_test_1): Match + more after $hex. + 2016-04-22 Yao Qi * gdb.base/annota1.exp: Set breakpoint on line $main_line. diff --git a/gdb/testsuite/gdb.trace/unavailable.exp b/gdb/testsuite/gdb.trace/unavailable.exp index 343ac6434d3..ed1b53363f8 100644 --- a/gdb/testsuite/gdb.trace/unavailable.exp +++ b/gdb/testsuite/gdb.trace/unavailable.exp @@ -613,7 +613,7 @@ proc gdb_collect_globals_test_1 { } { # whole object available gdb_test "print derived_whole" \ - " = \\(Derived\\) { = { = {x = 2}, _vptr.Middle = $hex, y = 3}, _vptr.Derived = $hex , z = 4}" + " = \\(Derived\\) { = { = {x = 2}, _vptr.Middle = ${hex}( <\[^>]*>)?, y = 3}, _vptr.Derived = $hex , z = 4}" } gdb_test_no_output "set print object off" @@ -631,7 +631,7 @@ proc gdb_collect_globals_test_1 { } { # whole object available gdb_test "print derived_whole" \ - " = { = { = {x = 2}, _vptr.Middle = $hex, y = 3}, _vptr.Derived = $hex , z = 4}" + " = { = { = {x = 2}, _vptr.Middle = ${hex}( <\[^>]*>)?, y = 3}, _vptr.Derived = $hex , z = 4}" } # An instance of a virtual class where we collected everything but -- 2.30.2