public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Philippe Waroquiers <philippe.waroquiers@skynet.be>
To: gdb-patches@sourceware.org
Cc: Philippe Waroquiers <philippe.waroquiers@skynet.be>
Subject: [RFA] Fix step-over-syscall.exp matching regexp for $bpnum.$locno matching
Date: Mon, 21 Nov 2022 00:36:14 +0100	[thread overview]
Message-ID: <20221120233614.388361-1-philippe.waroquiers@skynet.be> (raw)

step-over-syscall.exp has some specific tests for gdbserver.
The regexp matching breakpoint hit must take the added locno into account.

Test re-run in 3 modes (normal, native-gdbserver and native-extended-gdbserver).
---
 gdb/testsuite/gdb.base/step-over-syscall.exp | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/gdb/testsuite/gdb.base/step-over-syscall.exp b/gdb/testsuite/gdb.base/step-over-syscall.exp
index 788f6e3f5d0..3160900ad83 100644
--- a/gdb/testsuite/gdb.base/step-over-syscall.exp
+++ b/gdb/testsuite/gdb.base/step-over-syscall.exp
@@ -321,6 +321,7 @@ proc step_over_syscall { syscall } {
 # "on" or "off".
 
 proc break_cond_on_syscall { syscall follow_fork detach_on_fork } {
+    global bkptno_numopt_re
     with_test_prefix "break cond on target : $syscall" {
 	set testfile "step-over-$syscall"
 
@@ -368,12 +369,12 @@ proc break_cond_on_syscall { syscall follow_fork detach_on_fork } {
 		if { $detach_on_fork == "off" } {
 		    gdb_test "inferior 1"
 		    gdb_test "break marker" "Breakpoint.*at.*"
-		    gdb_test "continue" "Continuing\\..*Breakpoint \[0-9\]+, marker \\(\\) at.*" \
+		    gdb_test "continue" "Continuing\\..*Breakpoint $bkptno_numopt_re, marker \\(\\) at.*" \
 			"continue to marker"
 		}
 	    } else {
 		gdb_test "break marker" "Breakpoint.*at.* file .*${testfile}.c, line.*"
-		gdb_test "continue" "Continuing\\..*Breakpoint \[0-9\]+, marker \\(\\) at.*" \
+		gdb_test "continue" "Continuing\\..*Breakpoint $bkptno_numopt_re, marker \\(\\) at.*" \
 		    "continue to marker"
 	    }
 	}
-- 
2.30.2


             reply	other threads:[~2022-11-20 23:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-20 23:36 Philippe Waroquiers [this message]
2022-11-21 12:58 ` Simon Marchi
2022-11-21 20:15   ` Philippe Waroquiers

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=20221120233614.388361-1-philippe.waroquiers@skynet.be \
    --to=philippe.waroquiers@skynet.be \
    --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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).