gdb: rename find_pc_line_symtab -> find_symtab_for_pc

Change-Id: I2940e0f80c4b1d63fb1aee85f5753df5fbf4326a
Approved-by: Kevin Buettner <kevinb@redhat.com>
This commit is contained in:
Simon Marchi
2025-10-15 20:08:03 -04:00
committed by Simon Marchi
parent 1f76b668ff
commit 179801c964
7 changed files with 7 additions and 7 deletions

View File

@@ -1150,7 +1150,7 @@ gdb_disassembly (struct gdbarch *gdbarch, struct ui_out *uiout,
int nlines = -1;
/* Assume symtab is valid for whole PC range. */
symtab = find_pc_line_symtab (low);
symtab = find_symtab_for_pc (low);
if (symtab != NULL && symtab->linetable () != NULL)
nlines = symtab->linetable ()->nitems;

View File

@@ -709,7 +709,7 @@ btrace_find_line_range (CORE_ADDR pc)
struct symtab *symtab;
int nlines, i;
symtab = find_pc_line_symtab (pc);
symtab = find_symtab_for_pc (pc);
if (symtab == NULL)
return btrace_mk_line_range (NULL, 0, 0);

View File

@@ -447,7 +447,7 @@ maintenance_print_symbols (const char *args, int from_tty)
if (address_arg != NULL)
{
CORE_ADDR pc = parse_and_eval_address (address_arg);
struct symtab *s = find_pc_line_symtab (pc);
struct symtab *s = find_symtab_for_pc (pc);
if (s == NULL)
error (_("No symtab for address: %s"), address_arg);

View File

@@ -3246,7 +3246,7 @@ find_line_range_start (CORE_ADDR pc)
/* See symtab.h. */
struct symtab *
find_pc_line_symtab (CORE_ADDR pc)
find_symtab_for_pc (CORE_ADDR pc)
{
struct symtab_and_line sal;

View File

@@ -2430,7 +2430,7 @@ extern std::optional<CORE_ADDR> find_line_range_start (CORE_ADDR pc);
/* Wrapper around find_sal_for_pc to just return the symtab. */
extern struct symtab *find_pc_line_symtab (CORE_ADDR);
extern struct symtab *find_symtab_for_pc (CORE_ADDR);
/* Given a symtab and line number, return the pc there. */

View File

@@ -157,7 +157,7 @@ tui_source_window::do_scroll_vertical (int num_to_scroll)
if (cursal.symtab == NULL)
{
frame_info_ptr fi = get_selected_frame (NULL);
s = find_pc_line_symtab (get_frame_pc (fi));
s = find_symtab_for_pc (get_frame_pc (fi));
arch = get_frame_arch (fi);
}
else

View File

@@ -55,7 +55,7 @@ tui_display_main ()
tui_batch_rendering defer;
tui_update_source_windows_with_addr (gdbarch, addr);
struct symtab *s = find_pc_line_symtab (addr);
struct symtab *s = find_symtab_for_pc (addr);
tui_location.set_location (s);
}
}