From: Luis <luis.machado.foss@gmail.com>
To: Kevin Buettner <kevinb@redhat.com>,
Simon Marchi <simon.marchi@efficios.com>
Cc: gdb-patches@sourceware.org, Simon Marchi <simon.marchi@polymtl.ca>
Subject: Re: [PATCH] gdb: rename gdbarch_software_single_step -> gdbarch_get_next_pcs
Date: Tue, 19 Aug 2025 00:24:41 +0100 [thread overview]
Message-ID: <335c9e3c-12ca-417c-a6f7-c7d208268797@gmail.com> (raw)
In-Reply-To: <20250815200908.131101fa@f41-zbm-amd>
On 8/16/25 04:09, Kevin Buettner wrote:
> On Thu, 14 Aug 2025 16:14:17 -0400
> Simon Marchi <simon.marchi@efficios.com> wrote:
>
>> From: Simon Marchi <simon.marchi@efficios.com>
>> To: gdb-patches@sourceware.org
>> Cc: Simon Marchi <simon.marchi@polymtl.ca>
>> Subject: [PATCH] gdb: rename gdbarch_software_single_step ->
>> gdbarch_get_next_pcs Date: Thu, 14 Aug 2025 16:14:17 -0400
>>
>> From: Simon Marchi <simon.marchi@polymtl.ca>
>>
>> I spotted this while reviewing a patch adding a new
>> gdbarch_software_single_step implementation. I find the name
>> "software_single_step" a bit misleading or unclear. It makes it sounds
>> as if the function executed a single step. In reality, this function
>> returns the possible next PCs for current instructions.
>>
>> We have a similar concept in GDBserver:
>> linux_process_target::low_get_next_pcs. I like that name, it's clear
>> and straight to the point.
>>
>> Rename gdbarch_software_single_step to gdbarch_get_next_pcs. I find
>> this name more indicative of what happens.
>>
>> There is some code for ARM shared between GDB and GDBserver to implement
>> both sides, also called "get next pcs", so I think it all fits well
>> together.
>>
>> Tested by rebuilding.
>
> This one makes sense to me too.
>
> Approved-by: Kevin Buettner <kevinb@redhat.com>
>
Agreed. The naming has confused me in the past as well.
next prev parent reply other threads:[~2025-08-18 23:25 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-14 20:14 Simon Marchi
2025-08-16 3:09 ` Kevin Buettner
2025-08-18 23:24 ` Luis [this message]
2025-08-19 13:48 ` Simon Marchi
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=335c9e3c-12ca-417c-a6f7-c7d208268797@gmail.com \
--to=luis.machado.foss@gmail.com \
--cc=gdb-patches@sourceware.org \
--cc=kevinb@redhat.com \
--cc=simon.marchi@efficios.com \
--cc=simon.marchi@polymtl.ca \
/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