mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-10 09:33:36 +00:00
gdb: rename gdbarch_software_single_step -> gdbarch_get_next_pcs
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. Change-Id: Ide74011a5034ba11117b7e7c865a093ef0b1dece Approved-by: Kevin Buettner <kevinb@redhat.com> Acked-by: Luis Machado <luis.machado.foss@gmail.com>
This commit is contained in:
committed by
Simon Marchi
parent
1bf1357c68
commit
1d5f884e50
@@ -1395,7 +1395,7 @@ the condition is true, so that we ensure forward progress when stepping
|
||||
past a conditional branch to self.
|
||||
""",
|
||||
type="std::vector<CORE_ADDR>",
|
||||
name="software_single_step",
|
||||
name="get_next_pcs",
|
||||
params=[("struct regcache *", "regcache")],
|
||||
predicate=True,
|
||||
)
|
||||
@@ -1891,7 +1891,7 @@ receive control again (e.g. by placing a software breakpoint instruction into
|
||||
the displaced instruction buffer).
|
||||
|
||||
The default implementation returns false on all targets that provide a
|
||||
gdbarch_software_single_step routine, and true otherwise.
|
||||
gdbarch_get_next_pcs routine, and true otherwise.
|
||||
""",
|
||||
type="bool",
|
||||
name="displaced_step_hw_singlestep",
|
||||
|
||||
Reference in New Issue
Block a user