From: Tom Tromey <tom@tromey.com>
To: Bruno Larsen via Gdb-patches <gdb-patches@sourceware.org>
Cc: Bruno Larsen <blarsen@redhat.com>
Subject: Re: [PATCH v2 3/4] gdb/testsuite: fix testing gdb.reverse/step-reverse.exp with clang
Date: Fri, 28 Jul 2023 07:14:29 -0600 [thread overview]
Message-ID: <873518i3ey.fsf@tromey.com> (raw)
In-Reply-To: <20230727074118.1583199-4-blarsen@redhat.com> (Bruno Larsen via Gdb-patches's message of "Thu, 27 Jul 2023 09:41:17 +0200")
>>>>> "Bruno" == Bruno Larsen via Gdb-patches <gdb-patches@sourceware.org> writes:
Bruno> It also adds a new parameter to get_hexadecimal_valueof, so that we can
Bruno> use it without generating new passes, otherwise we'd get multiple
Bruno> duplicate test names. This change shouldn't affect any other test using
Bruno> this proc.
You can just pass different test names instead.
Bruno> +proc get_current_pc {} {
Bruno> + set pc 0
Bruno> + gdb_test_multiple "print \$pc" "" {
Bruno> + -re -wrap ".*0x(\[0-9a-f\]+).*" {
Bruno> + set pc $expect_out(1,string)
Bruno> + }
Bruno> + }
Bruno> + return $pc
It seems to me that this shouldn't be needed.
Bruno> diff --git a/gdb/testsuite/gdb.reverse/step-reverse.exp b/gdb/testsuite/gdb.reverse/step-reverse.exp
Bruno> index 4b78a8f8fb7..9ff97bfde42 100644
Bruno> --- a/gdb/testsuite/gdb.reverse/step-reverse.exp
Bruno> +++ b/gdb/testsuite/gdb.reverse/step-reverse.exp
Bruno> @@ -28,6 +28,16 @@ if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } {
Bruno> return -1
Bruno> }
Bruno> +proc get_current_pc {} {
Bruno> + set pc 0
Bruno> + gdb_test_multiple "print \$pc" "" {
Bruno> + -re -wrap ".*0x(\[0-9a-f\]+).*" {
Bruno> + set pc $expect_out(1,string)
Bruno> + }
Bruno> + }
Bruno> + return $pc
Same with this one.
Tom
next prev parent reply other threads:[~2023-07-28 13:14 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-25 9:58 [PATCH 0/4] Many fixes to gdb.reverse tests Bruno Larsen
2023-07-25 9:58 ` [PATCH 1/4] gdb/testsuite: Fix many errors in gdb.reverse with clang Bruno Larsen
2023-07-25 9:58 ` [PATCH 2/4] gdb/testsuite: fix gdb.reverse/solib-*.exp tests when using clang Bruno Larsen
2023-07-26 13:37 ` Tom Tromey
2023-07-25 9:58 ` [PATCH 3/4] gdb/testsuite: fix testing gdb.reverse/step-reverse.exp with clang Bruno Larsen
2023-07-26 13:39 ` Tom Tromey
2023-07-25 9:58 ` [PATCH 4/4] gdb/testsuite: Multiple improvements for gdb.reverse/insn-reverse.exp Bruno Larsen
2023-07-27 7:41 ` [PATCH v2 0/4] Many fixes to gdb.reverse tests Bruno Larsen
2023-07-27 7:41 ` [PATCH v2 1/4] gdb/testsuite: Fix many errors in gdb.reverse with clang Bruno Larsen
2023-07-27 7:41 ` [PATCH v2 2/4] gdb/testsuite: fix gdb.reverse/solib-*.exp tests when using clang Bruno Larsen
2023-07-27 7:41 ` [PATCH v2 3/4] gdb/testsuite: fix testing gdb.reverse/step-reverse.exp with clang Bruno Larsen
2023-07-28 13:14 ` Tom Tromey [this message]
2023-07-28 13:20 ` Bruno Larsen
2023-07-28 14:18 ` Tom Tromey
2023-07-28 14:20 ` Bruno Larsen
2023-07-27 7:41 ` [PATCH v2 4/4] gdb/testsuite: Multiple improvements for gdb.reverse/insn-reverse.exp Bruno Larsen
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=873518i3ey.fsf@tromey.com \
--to=tom@tromey.com \
--cc=blarsen@redhat.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).