Backward compatibility, no section */
struct symbol *
-find_pc_function (CORE_ADDR pc)
+find_symbol_for_pc (CORE_ADDR pc)
{
return find_pc_sect_function (pc, find_pc_mapped_section (pc));
}
struct type *
find_function_type (CORE_ADDR pc)
{
- struct symbol *sym = find_pc_function (pc);
+ struct symbol *sym = find_symbol_for_pc (pc);
if (sym != NULL && sym->value_block ()->entry_pc () == pc)
return sym->type ();
only a minimal symbol. */
if (pc.has_value ())
{
- fun = find_pc_function (*pc);
+ fun = find_symbol_for_pc (*pc);
bound_minimal_symbol bmfun = lookup_minimal_symbol_by_pc (*pc);
mfun = bmfun.minsym;
paddress (get_current_arch (), sal.pc));
gdbarch = sal.symtab->compunit ()->objfile ()->arch ();
- sym = find_pc_function (sal.pc);
+ sym = find_symbol_for_pc (sal.pc);
if (sym)
gdb_printf ("%ps is in %ps (%ps:%ps).\n",
styled_string (address_style.style (),
paddress (get_current_arch (), sal.pc));
gdbarch = sal.symtab->compunit ()->objfile ()->arch ();
- sym = find_pc_function (sal.pc);
+ sym = find_symbol_for_pc (sal.pc);
if (sym)
gdb_printf ("%s is in %s (%s:%d).\n",
paddress (gdbarch, sal.pc),
static struct symbol *
func_addr_to_tail_call_list (struct gdbarch *gdbarch, CORE_ADDR addr)
{
- struct symbol *sym = find_pc_function (addr);
+ struct symbol *sym = find_symbol_for_pc (addr);
struct type *type;
if (sym == NULL || sym->value_block ()->entry_pc () != addr)
(exp->gdbarch, addr, current_inferior ()->top_target ());
/* Is it a high_level symbol? */
- sym = find_pc_function (addr);
+ sym = find_symbol_for_pc (addr);
if (sym != NULL)
method = value_of_variable (sym, 0);
}
if (frame != NULL)
{
found = true;
- sym = find_pc_function (get_frame_address_in_block (frame));
+ sym = find_symbol_for_pc (get_frame_address_in_block (frame));
}
}
catch (const gdb_exception &except)
get_function_name (CORE_ADDR funaddr, char *buf, int buf_size)
{
{
- struct symbol *symbol = find_pc_function (funaddr);
+ struct symbol *symbol = find_symbol_for_pc (funaddr);
if (symbol)
return symbol->print_name ();
set_step_info (tp, frame, sal);
CORE_ADDR pc = get_frame_pc (frame);
- tp->control.step_start_function = find_pc_function (pc);
+ tp->control.step_start_function = find_symbol_for_pc (pc);
}
/* Step until outside of current statement. */
not). */
pc = get_frame_pc (frame);
- func = find_pc_function (pc);
+ func = find_symbol_for_pc (pc);
if (!func)
{
/* Find the function we will return from. */
frame_info_ptr callee_frame = get_selected_frame (nullptr);
- sm->function = find_pc_function (get_frame_pc (callee_frame));
+ sm->function = find_symbol_for_pc (get_frame_pc (callee_frame));
sm->return_buf = 0; /* Initialize buffer address is not available. */
/* Determine the return convention. If it is RETURN_VALUE_STRUCT_CONVENTION,
&& ((ecs->event_thread->control.step_stack_frame_id
!= outer_frame_id)
|| (ecs->event_thread->control.step_start_function
- != find_pc_function (ecs->event_thread->stop_pc ())))))
+ != find_symbol_for_pc (ecs->event_thread->stop_pc ())))))
{
CORE_ADDR stop_pc = ecs->event_thread->stop_pc ();
CORE_ADDR real_stop_pc;
&& (tp->control.step_frame_id
== get_frame_id (get_current_frame ()))
&& (tp->control.step_start_function
- == find_pc_function (tp->stop_pc ())))
+ == find_symbol_for_pc (tp->stop_pc ())))
{
symtab_and_line sal = find_frame_sal (get_selected_frame (nullptr));
if (sal.symtab != tp->current_symtab)
{
if ((pc = get_frame_pc_if_available (frame)))
{
- struct symbol *function = find_pc_function (*pc);
+ struct symbol *function = find_symbol_for_pc (*pc);
if (function != nullptr)
{
struct type *ret_type =
/* Attempt to find the name of the function. If the name is available,
it'll be used as an aid in finding matching functions in the dynamic
symbol table. */
- sym = find_pc_function (entry_point);
+ sym = find_symbol_for_pc (entry_point);
if (sym == 0)
name = 0;
else
cache = sparc_frame_cache (this_frame, this_cache);
- sym = find_pc_function (cache->pc);
+ sym = find_symbol_for_pc (cache->pc);
if (sym)
{
cache->struct_return_p = sparc32_struct_return_from_sym (sym);
sparc32_dwarf2_struct_return_p (const frame_info_ptr &this_frame)
{
CORE_ADDR pc = get_frame_address_in_block (this_frame);
- struct symbol *sym = find_pc_function (pc);
+ struct symbol *sym = find_symbol_for_pc (pc);
if (sym)
return sparc32_struct_return_from_sym (sym);
if (!msymbol_is_function (msymbol.objfile, msymbol.minsym, &func_addr))
return NULL;
- symbol *sym = find_pc_function (func_addr);
+ symbol *sym = find_symbol_for_pc (func_addr);
if (sym != NULL
&& sym->loc_class () == LOC_BLOCK
&& sym->value_block ()->entry_pc () == func_addr)
return value will not be an inlined function; the containing
function will be returned instead. */
-extern struct symbol *find_pc_function (CORE_ADDR);
+extern struct symbol *find_symbol_for_pc (CORE_ADDR);
/* lookup the function corresponding to the address and section. The
return value will not be an inlined function; the containing
&& (trace_pc = get_frame_pc_if_available (trace_frame)))
{
traceframe_sal = find_pc_line (*trace_pc, 0);
- traceframe_fun = find_pc_function (*trace_pc);
+ traceframe_fun = find_symbol_for_pc (*trace_pc);
/* Save linenumber as "$trace_line", a debugger variable visible to
users. */