45#include "gdbsupport/scope-exit.h"
54#define infcall_debug_printf(fmt, ...) \
55 debug_prefixed_printf_cond (debug_infcall, "infcall", fmt, ##__VA_ARGS__)
59#define INFCALL_SCOPED_DEBUG_ENTER_EXIT \
60 scoped_debug_enter_exit (debug_infcall, "infcall")
64#define INFCALL_SCOPED_DEBUG_START_END(fmt, ...) \
65 scoped_debug_start_end (debug_infrun, "infcall", fmt, ##__VA_ARGS__)
78#define RAW_FUNCTION_ADDRESS_FORMAT "at 0x%s"
79#define RAW_FUNCTION_ADDRESS_SIZE (sizeof (RAW_FUNCTION_ADDRESS_FORMAT) \
80 + 2 * sizeof (CORE_ADDR))
95 _(
"Permission to call functions in the program is %s.\n"),
125 _(
"Coercion of floats to doubles "
126 "when calling functions is %s.\n"),
143 _(
"Unwinding of stack if a signal is "
144 "received while in a call dummy is %s.\n"),
169 _(
"Unwind stack if a C++ exception is "
170 "unhandled while in a call dummy is %s.\n"),
182 struct type *param_type,
int is_prototyped)
204 case TYPE_CODE_RVALUE_REF:
206 struct value *new_value;
247 case TYPE_CODE_ARRAY:
257 case TYPE_CODE_STRUCT:
258 case TYPE_CODE_UNION:
261 case TYPE_CODE_RANGE:
262 case TYPE_CODE_STRING:
263 case TYPE_CODE_ERROR:
264 case TYPE_CODE_MEMBERPTR:
265 case TYPE_CODE_METHODPTR:
266 case TYPE_CODE_METHOD:
267 case TYPE_CODE_COMPLEX:
279 struct type **retval_type,
280 struct type **function_type)
284 struct type *value_type = NULL;
286 CORE_ADDR funaddr = 0;
292 if (ftype->
code () == TYPE_CODE_FUNC
293 || ftype->
code () == TYPE_CODE_METHOD)
294 funaddr = function->
address ();
295 else if (ftype->
code () == TYPE_CODE_PTR)
299 if (ftype->
code () == TYPE_CODE_FUNC
300 || ftype->
code () == TYPE_CODE_METHOD)
304 if (ftype->
code () == TYPE_CODE_FUNC
305 || ftype->
code () == TYPE_CODE_METHOD)
309 CORE_ADDR resolver_addr = funaddr;
317 if (retval_type != NULL || function_type != NULL)
323 if (target_ftype == NULL)
325 if (target_ftype != NULL)
328 ftype = target_ftype;
335 else if (ftype->
code () == TYPE_CODE_INT)
339 if (ftype->
length () == 1)
344 int found_descriptor = 0;
355 if (funaddr != nfunaddr)
356 found_descriptor = 1;
358 if (!found_descriptor)
364 error (_(
"Invalid data type for function to be called."));
366 if (retval_type != NULL)
367 *retval_type = value_type;
368 if (function_type != NULL)
369 *function_type = ftype;
378 CORE_ADDR sp, CORE_ADDR funaddr,
379 gdb::array_view<value *> args,
380 struct type *value_type,
381 CORE_ADDR *real_pc, CORE_ADDR *bp_addr,
387 args.data (), args.size (),
388 value_type, real_pc, bp_addr,
397 if (func_name != NULL)
398 error (_(
"'%s' has unknown return type; "
399 "cast the call to its declared return type"),
402 error (_(
"function has unknown return type; "
403 "cast the call to its declared return type"));
432 hex_string (funaddr));
434 gdb_assert (tmp.length () + 1 <= buf_size);
435 return strcpy (buf, tmp.c_str ());
465 struct value *retval = NULL;
473 if (stack_temporaries)
501 gdb_assert (retval != NULL);
524 struct type *value_type,
525 int struct_return_p, CORE_ADDR struct_addr);
535 struct interp *cmd_interp,
537 struct value *function,
538 struct type *value_type,
539 int struct_return_p, CORE_ADDR struct_addr)
541 waiting_ui (waiting_ui)
631static struct gdb_exception
633 struct
thread_info *call_thread, CORE_ADDR real_pc)
637 struct gdb_exception caught_error;
638 ptid_t call_thread_ptid = call_thread->ptid;
642 core_addr_to_string (real_pc),
643 call_thread_ptid.to_string ().c_str (),
648 scoped_restore restore_in_infcall
649 = make_scoped_restore (&call_thread->control.in_infcall, 1);
655 call_thread->set_thread_fsm (std::move (sm));
660 call_thread->control.proceed_to_finish = 1;
665 scoped_restore restore_prompt_state
670 scoped_restore restore_ui_async
673 proceed (real_pc, GDB_SIGNAL_0);
684 catch (gdb_exception &e)
687 e.reason, e.what ());
688 caught_error = std::move (e);
715 if (call_thread->thread_fsm ()->finished_p ())
749 if (caught_error.reason < 0)
774 sp -= values_type->
length ();
786 sp += values_type->
length ();
812 struct type *default_return_type)
814 for (
auto vals : dtors_to_invoke)
817 gdb::make_array_view (&(vals.self), 1));
825 type *default_return_type,
826 gdb::array_view<value *> args)
852 type *default_return_type,
853 gdb::array_view<value *> args,
855 void *dummy_dtor_data)
860 struct type *target_values_type;
862 CORE_ADDR struct_addr = 0;
868 ptid_t call_thread_ptid;
869 struct gdb_exception e;
873 error (_(
"Cannot call functions in the program: "
874 "may-call-functions is off."));
880 error (_(
"May not call functions while looking at trace frames."));
883 error (_(
"Cannot call functions in reverse mode."));
897 error (_(
"This target does not support function calls."));
905 error (_(
"Cannot call the function '%s' which does not follow the "
906 "target calling convention."),
909 if (values_type == NULL || values_type->
is_stub ())
910 values_type = default_return_type;
911 if (values_type == NULL)
914 name_buf,
sizeof (name_buf));
915 error (_(
"'%s' has unknown return type; "
916 "cast the call to its declared return type"),
923 error (_(
"Too few arguments in function call."));
1007 if (stack_temporaries)
1009 struct value *lastval;
1012 if (lastval != NULL)
1014 CORE_ADDR lastval_addr = lastval->
address ();
1018 gdb_assert (sp >= lastval_addr);
1023 gdb_assert (sp <= lastval_addr);
1024 sp = lastval_addr + lastval->
type ()->
length ();
1047 target_values_type = values_type;
1062 const gdb_byte *bp_bytes;
1063 CORE_ADDR bp_addr_as_address;
1070 target_values_type, &real_pc, &bp_addr,
1084 bp_addr_as_address = bp_addr;
1087 if (bp_bytes != NULL)
1093 CORE_ADDR dummy_addr;
1103 bp_addr = dummy_addr;
1107 internal_error (_(
"bad switch"));
1114 std::list<destructor_info> dtors_to_invoke;
1116 for (
int i = args.size () - 1; i >= 0; i--)
1119 struct type *param_type;
1123 if (ftype->
code () == TYPE_CODE_METHOD)
1126 && default_return_type != NULL)
1150 value *original_arg = args[i];
1152 param_type, prototyped);
1154 if (param_type == NULL)
1158 if (!info.copy_constructible)
1159 error (_(
"expression cannot be evaluated because the type '%s' "
1160 "is not copy constructible"), param_type->
name ());
1162 if (!info.destructible)
1163 error (_(
"expression cannot be evaluated because the type '%s' "
1164 "is not destructible"), param_type->
name ());
1166 if (info.trivially_copyable)
1179 if (info.trivially_copy_constructible)
1187 value *cctor_args[2] = { clone_ptr, original_arg };
1190 &clone_ptr,
nullptr, ©_ctor,
nullptr,
1193 if (copy_ctor ==
nullptr)
1194 error (_(
"expression cannot be evaluated because a copy "
1195 "constructor for the type '%s' could not be found "
1196 "(maybe inlined?)"), param_type->
name ());
1199 gdb::make_array_view (cctor_args, 2));
1204 if (!info.trivially_destructible)
1211 const char *dtor_name =
nullptr;
1212 for (
int fieldnum = 0;
1225 if (dtor_name ==
nullptr)
1226 error (_(
"expression cannot be evaluated because a destructor "
1227 "for the type '%s' could not be found "
1228 "(maybe inlined?)"), param_type->
name ());
1235 dtors_to_invoke.emplace_front (dtor, clone_ptr);
1238 args[i] = clone_ptr;
1259 std::vector<struct value *> new_args;
1263 new_args.reserve (1 + args.size ());
1266 new_args.insert (new_args.end (), args.begin (), args.end ());
1274 bp_addr, args.size (), args.data (),
1275 sp, return_method, struct_addr);
1338 if (dummy_dtor != NULL)
1340 dummy_dtor, dummy_dtor_data);
1351 scoped_restore restore_stopped_by_random_signal
1360 std::unique_ptr<thread_fsm> saved_sm = call_thread->release_thread_fsm ();
1365 call_thread_ptid = call_thread->ptid;
1379 std::unique_ptr<call_thread_fsm> sm_up (sm);
1385 e.reason, e.what ());
1394 gdb_assert (call_thread->thread_fsm () == sm);
1396 if (call_thread->thread_fsm ()->finished_p ())
1398 struct value *retval;
1416 std::unique_ptr<thread_fsm> finalizing
1417 = call_thread->release_thread_fsm ();
1418 call_thread->set_thread_fsm (std::move (saved_sm));
1420 finalizing->clean_up (call_thread.get ());
1425 gdb_assert (retval != NULL);
1438 std::unique_ptr<thread_fsm> finalizing
1439 = call_thread->release_thread_fsm ();
1440 call_thread->set_thread_fsm (std::move (saved_sm));
1442 finalizing->clean_up (call_thread.get ());
1452 name_buf,
sizeof (name_buf));
1463 throw_error (e.error, _(
"%s\n\
1464An error occurred while in a function called from GDB.\n\
1465Evaluation of the expression containing the function\n\
1466(%s) will be abandoned.\n\
1467When the function is done executing, GDB will silently stop."),
1471 throw_exception (std::move (e));
1481 name_buf,
sizeof (name_buf));
1491 error (_(
"The program being debugged exited while in a function "
1492 "called from GDB.\n"
1493 "Evaluation of the expression containing the function\n"
1494 "(%s) will be abandoned."),
1501 name_buf,
sizeof (name_buf));
1512The program received a signal in another thread while\n\
1513making a function call from GDB.\n\
1514Evaluation of the expression containing the function\n\
1515(%s) will be abandoned.\n\
1516When the function is done executing, GDB will silently stop."),
1520The program stopped in another thread while making a function call from GDB.\n\
1521Evaluation of the expression containing the function\n\
1522(%s) will be abandoned.\n\
1523When the function is done executing, GDB will silently stop."),
1545 gdb_signal stop_signal = call_thread->stop_signal ();
1558The program being debugged received signal %s, %s\n\
1559while in a function called from GDB. GDB has restored the context\n\
1560to what it was before the call. To change this behavior use\n\
1561\"set unwindonsignal off\". Evaluation of the expression containing\n\
1562the function (%s) will be abandoned."),
1563 gdb_signal_to_name (stop_signal),
1564 gdb_signal_to_string (stop_signal),
1578The program being debugged was signaled while in a function called from GDB.\n\
1579GDB remains in the frame where the signal was received.\n\
1580To change this behavior use \"set unwindonsignal on\".\n\
1581Evaluation of the expression containing the function\n\
1582(%s) will be abandoned.\n\
1583When the function is done executing, GDB will silently stop."),
1599The program being debugged entered a std::terminate call, most likely\n\
1600caused by an unhandled C++ exception. GDB blocked this call in order\n\
1601to prevent the program from being terminated, and has restored the\n\
1602context to its original state before the call.\n\
1603To change this behaviour use \"set unwind-on-terminating-exception off\".\n\
1604Evaluation of the expression containing the function (%s)\n\
1605will be abandoned."),
1626The program being debugged stopped while in a function called from GDB.\n\
1627Evaluation of the expression containing the function\n\
1628(%s) will be abandoned.\n\
1629When the function is done executing, GDB will silently stop."),
1636 gdb_assert_not_reached (
"... should not be here");
1645Set permission to call functions in the program."), _(
"\
1646Show permission to call functions in the program."), _(
"\
1647When this permission is on, GDB may call functions in the program.\n\
1648Otherwise, any sort of attempt to call a function in the program\n\
1649will result in an error."),
1656Set coercion of floats to doubles when calling functions."), _(
"\
1657Show coercion of floats to doubles when calling functions."), _(
"\
1658Variables of type float should generally be converted to doubles before\n\
1659calling an unprototyped function, and left alone when calling a prototyped\n\
1660function. However, some older debug info formats do not provide enough\n\
1661information to determine that a function is prototyped. If this flag is\n\
1662set, GDB will perform the conversion for a function it considers\n\
1664The default is to perform the conversion."),
1671Set unwinding of stack if a signal is received while in a call dummy."), _(
"\
1672Show unwinding of stack if a signal is received while in a call dummy."), _(
"\
1673The unwindonsignal lets the user determine what gdb should do if a signal\n\
1674is received while in a function called from gdb (call dummy). If set, gdb\n\
1675unwinds the stack and restore the context to what as it was before the call.\n\
1676The default is to stop in the frame where the signal was received."),
1683Set unwinding of stack if std::terminate is called while in call dummy."), _(
"\
1684Show unwinding of stack if std::terminate() is called while in a call dummy."),
1686The unwind on terminating exception flag lets the user determine\n\
1687what gdb should do if a std::terminate() call is made from the\n\
1688default exception handler. If set, gdb unwinds the stack and restores\n\
1689the context to what it was before the call. If unset, gdb allows the\n\
1690std::terminate call to proceed.\n\
1691The default is to unwind the frame."),
1698 _(
"Set inferior call debugging."),
1699 _(
"Show inferior call debugging."),
1700 _(
"When on, inferior function call specific debugging is enabled."),
struct value * ada_convert_actual(struct value *actual, struct type *formal_type0)
struct symbol * find_pc_function(CORE_ADDR pc)
struct type * find_function_type(CORE_ADDR pc)
struct type * find_gnu_ifunc_target_type(CORE_ADDR resolver_funaddr)
void set_std_terminate_breakpoint(void)
void breakpoint_auto_delete(bpstat *bs)
void delete_std_terminate_breakpoint(void)
void enable_watchpoints_after_interactive_call_stop(void)
struct breakpoint * set_longjmp_breakpoint_for_call_dummy(void)
void disable_watchpoints_before_interactive_call_start(void)
breakpoint_up set_momentary_breakpoint(struct gdbarch *gdbarch, struct symtab_and_line sal, struct frame_id frame_id, enum bptype type)
struct cmd_list_element * showlist
struct cmd_list_element * setlist
struct cmd_list_element * showdebuglist
struct cmd_list_element * setdebuglist
set_show_commands add_setshow_boolean_cmd(const char *name, enum command_class theclass, bool *var, const char *set_doc, const char *show_doc, const char *help_doc, cmd_func_ftype *set_func, show_value_ftype *show_func, struct cmd_list_element **set_list, struct cmd_list_element **show_list)
void write_memory(CORE_ADDR memaddr, const bfd_byte *myaddr, ssize_t len)
void register_dummy_frame_dtor(frame_id dummy_id, thread_info *thread, dummy_frame_dtor_ftype *dtor, void *dtor_data)
void dummy_frame_pop(frame_id dummy_id, thread_info *thread)
void dummy_frame_push(struct infcall_suspend_state *caller_state, const frame_id *dummy_id, thread_info *thread)
void dummy_frame_dtor_ftype(void *data, int registers_valid)
void async_enable_stdin(void)
void async_disable_stdin(void)
struct type * fortran_preserve_arg_pointer(struct value *arg, struct type *type)
CORE_ADDR get_frame_sp(frame_info_ptr this_frame)
struct frame_id frame_id_build(CORE_ADDR stack_addr, CORE_ADDR code_addr)
struct gdbarch * get_frame_arch(frame_info_ptr this_frame)
frame_info_ptr get_current_frame(void)
enum call_dummy_location_type gdbarch_call_dummy_location(struct gdbarch *gdbarch)
enum return_value_convention gdbarch_return_value_as_value(struct gdbarch *gdbarch, struct value *function, struct type *valtype, struct regcache *regcache, struct value **read_value, const gdb_byte *writebuf)
const gdb_byte * gdbarch_breakpoint_from_pc(struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr)
CORE_ADDR gdbarch_push_dummy_call(struct gdbarch *gdbarch, struct value *function, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, function_call_return_method return_method, CORE_ADDR struct_addr)
CORE_ADDR gdbarch_frame_align(struct gdbarch *gdbarch, CORE_ADDR address)
int gdbarch_return_in_first_hidden_param_p(struct gdbarch *gdbarch, struct type *type)
CORE_ADDR gdbarch_deprecated_function_start_offset(struct gdbarch *gdbarch)
CORE_ADDR gdbarch_push_dummy_code(struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr, struct regcache *regcache)
bool gdbarch_push_dummy_call_p(struct gdbarch *gdbarch)
int gdbarch_frame_red_zone_size(struct gdbarch *gdbarch)
bool gdbarch_push_dummy_code_p(struct gdbarch *gdbarch)
int gdbarch_inner_than(struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs)
CORE_ADDR gdbarch_convert_from_func_ptr_addr(struct gdbarch *gdbarch, CORE_ADDR addr, struct target_ops *targ)
bool gdbarch_frame_align_p(struct gdbarch *gdbarch)
function_call_return_method
@ return_method_hidden_param
const char * thread_state_string(enum thread_state state)
all_non_exited_threads_range all_non_exited_threads(process_stratum_target *proc_target=nullptr, ptid_t filter_ptid=minus_one_ptid)
void finish_thread_state(process_stratum_target *targ, ptid_t ptid)
struct thread_info * inferior_thread(void)
value * get_last_thread_stack_temporary(struct thread_info *tp)
void push_thread_stack_temporary(struct thread_info *tp, struct value *v)
bool thread_stack_temporaries_enabled_p(struct thread_info *tp)
gdb::ref_ptr< struct thread_info, refcounted_object_ref_policy > thread_info_ref
struct type * lookup_pointer_type(struct type *type)
int class_or_union_p(const struct type *t)
bool is_nocall_function(const struct type *type)
const struct builtin_type * builtin_type(struct gdbarch *gdbarch)
struct type * check_typedef(struct type *type)
#define TYPE_FN_FIELD_PHYSNAME(thisfn, n)
#define TYPE_NFN_FIELDS(thistype)
#define TYPE_IS_REFERENCE(t)
#define TYPE_FN_FIELDLIST1(thistype, n)
#define TYPE_FN_FIELDLIST_NAME(thistype, n)
static struct value * get_call_return_value(struct call_return_meta_info *ri)
static void show_may_call_functions_p(struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
static bool unwind_on_terminating_exception_p
struct value * call_function_by_hand_dummy(struct value *function, type *default_return_type, gdb::array_view< value * > args, dummy_frame_dtor_ftype *dummy_dtor, void *dummy_dtor_data)
CORE_ADDR find_function_addr(struct value *function, struct type **retval_type, struct type **function_type)
static bool coerce_float_to_double_p
#define infcall_debug_printf(fmt,...)
static struct gdb_exception run_inferior_call(std::unique_ptr< call_thread_fsm > sm, struct thread_info *call_thread, CORE_ADDR real_pc)
static void show_unwind_on_terminating_exception_p(struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
static CORE_ADDR push_dummy_code(struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, gdb::array_view< value * > args, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr, struct regcache *regcache)
void _initialize_infcall()
static bool may_call_functions_p
void error_call_unknown_return_type(const char *func_name)
static bool debug_infcall
#define RAW_FUNCTION_ADDRESS_FORMAT
static struct value * value_arg_coerce(struct gdbarch *gdbarch, struct value *arg, struct type *param_type, int is_prototyped)
static CORE_ADDR reserve_stack_space(const type *values_type, CORE_ADDR &sp)
static void show_unwind_on_signal_p(struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
static bool unwind_on_signal_p
struct value * call_function_by_hand(struct value *function, type *default_return_type, gdb::array_view< value * > args)
static void show_debug_infcall(struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
#define INFCALL_SCOPED_DEBUG_ENTER_EXIT
static void call_destructors(const std::list< destructor_info > &dtors_to_invoke, struct type *default_return_type)
#define RAW_FUNCTION_ADDRESS_SIZE
static void show_coerce_float_to_double_p(struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
static const char * get_function_name(CORE_ADDR funaddr, char *buf, int buf_size)
int stopped_by_random_signal
enum stop_stack_kind stop_stack_dummy
struct inferior * current_inferior(void)
void restore_infcall_control_state(struct infcall_control_state *)
std::unique_ptr< infcall_control_state, infcall_control_state_deleter > infcall_control_state_up
infcall_suspend_state_up save_infcall_suspend_state()
void discard_infcall_control_state(struct infcall_control_state *)
infcall_control_state_up save_infcall_control_state()
std::unique_ptr< infcall_suspend_state, infcall_suspend_state_deleter > infcall_suspend_state_up
void maybe_remove_breakpoints(void)
void clear_proceed_status(int step)
enum exec_direction_kind execution_direction
void proceed(CORE_ADDR addr, enum gdb_signal siggnal)
ptid_t user_visible_resume_ptid(int step)
static void infrun_debug_show_threads(const char *title, ThreadRange threads)
struct interp * command_interp(void)
const struct language_defn * current_language
struct language_pass_by_ref_info language_pass_by_reference(struct type *type)
struct bound_minimal_symbol lookup_minimal_symbol_by_pc(CORE_ADDR pc)
observable< ptid_t, CORE_ADDR > inferior_call_pre
observable< ptid_t, CORE_ADDR > inferior_call_post
CORE_ADDR entry_point_address(void)
struct program_space * current_program_space
static gdbpy_ref field_name(struct type *type, int field)
struct regcache * get_current_regcache(void)
struct minimal_symbol * minsym
breakpoint * related_breakpoint
struct type * builtin_double
struct type * builtin_long_double
struct type * builtin_int
struct type * builtin_void
struct value * return_value
bool should_stop(struct thread_info *thread) override
call_thread_fsm(struct ui *waiting_ui, struct interp *cmd_interp, struct gdbarch *gdbarch, struct value *function, struct type *value_type, int struct_return_p, CORE_ADDR struct_addr)
struct call_return_meta_info return_meta_info
bool should_notify_stop() override
destructor_info(struct value *function, struct value *self)
struct type * type() const
const char * print_name() const
enum language la_language
virtual bool c_style_arrays_p() const
struct obj_section * section
struct program_space * pspace
struct type * target_type() const
struct field & field(int idx) const
bool is_gnu_ifunc() const
unsigned int num_fields() const
const char * name() const
bool is_prototyped() const
enum prompt_state prompt_state
void unregister_file_handler()
void force_lval(CORE_ADDR)
static struct value * allocate(struct type *type)
struct type * type() const
enum lval_type lval() const
struct obj_section * find_pc_overlay(CORE_ADDR pc)
#define gnu_ifunc_resolve_addr
bool target_has_execution(inferior *inf)
void wait_sync_command_done(void)
int get_traceframe_number(void)
void gdb_printf(struct ui_file *stream, const char *format,...)
struct value * value_coerce_to_target(struct value *val)
struct value * value_cast_pointers(struct type *type, struct value *arg2, int subclass_check)
struct value * value_at_non_lval(struct type *type, CORE_ADDR addr)
struct value * value_addr(struct value *arg1)
struct value * find_function_in_inferior(const char *name, struct objfile **objf_p)
struct value * value_cast(struct type *type, struct value *arg2)
struct value * value_ref(struct value *arg1, enum type_code refcode)
int find_overload_match(gdb::array_view< value * > args, const char *name, enum oload_search_type method, struct value **objp, struct symbol *fsym, struct value **valp, struct symbol **symp, int *staticp, const int no_adl, const enum noside noside)
CORE_ADDR value_as_address(struct value *val)
LONGEST value_as_long(struct value *val)
struct value * value_from_pointer(struct type *type, CORE_ADDR addr)
int using_struct_return(struct gdbarch *gdbarch, struct value *function, struct type *value_type)
struct value * value_from_contents_and_address(struct type *type, const gdb_byte *valaddr, CORE_ADDR address, frame_info_ptr frame)