|
GDB (xrefs)
|
#include "defs.h"#include "ui-out.h"#include "value.h"#include "frame.h"#include "gdbcore.h"#include "target.h"#include "inferior.h"#include "ax.h"#include "ax-gdb.h"#include "regcache.h"#include "objfiles.h"#include "block.h"#include "gdbcmd.h"#include "complaints.h"#include "dwarf2.h"#include "dwarf2expr.h"#include "dwarf2loc.h"#include "dwarf2-frame.h"#include "compile/compile.h"#include "selftest.h"#include <algorithm>#include <vector>#include <unordered_set>#include "common/underlying.h"#include "common/byte-vector.h"Go to the source code of this file.
Classes | |
| struct | dwarf_expr_baton |
| class | dwarf_evaluate_loc_desc |
| struct | piece_closure |
| class | symbol_needs_eval_context |
Enumerations | |
| enum | debug_loc_kind { DEBUG_LOC_END_OF_LIST = 0, DEBUG_LOC_BASE_ADDRESS = 1, DEBUG_LOC_START_END = 2, DEBUG_LOC_START_LENGTH = 3, DEBUG_LOC_BUFFER_OVERFLOW = -1, DEBUG_LOC_INVALID_ENTRY = -2 } |
Functions | |
| static struct value * | dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame, const gdb_byte *data, size_t size, struct dwarf2_per_cu_data *per_cu, struct type *subobj_type, LONGEST subobj_byte_offset) |
| static struct call_site_parameter * | dwarf_expr_reg_to_entry_parameter (struct frame_info *frame, enum call_site_parameter_kind kind, union call_site_parameter_u kind_u, struct dwarf2_per_cu_data **per_cu_return) |
| static void | invalid_synthetic_pointer (void) |
| static enum debug_loc_kind | decode_debug_loc_addresses (const gdb_byte *loc_ptr, const gdb_byte *buf_end, const gdb_byte **new_ptr, CORE_ADDR *low, CORE_ADDR *high, enum bfd_endian byte_order, unsigned int addr_size, int signed_addr_p) |
| static enum debug_loc_kind | decode_debug_loclists_addresses (struct dwarf2_per_cu_data *per_cu, const gdb_byte *loc_ptr, const gdb_byte *buf_end, const gdb_byte **new_ptr, CORE_ADDR *low, CORE_ADDR *high, enum bfd_endian byte_order, unsigned int addr_size, int signed_addr_p) |
| static enum debug_loc_kind | decode_debug_loc_dwo_addresses (struct dwarf2_per_cu_data *per_cu, const gdb_byte *loc_ptr, const gdb_byte *buf_end, const gdb_byte **new_ptr, CORE_ADDR *low, CORE_ADDR *high, enum bfd_endian byte_order) |
| const gdb_byte * | dwarf2_find_location_expression (struct dwarf2_loclist_baton *baton, size_t *locexpr_length, CORE_ADDR pc) |
| static void | locexpr_find_frame_base_location (struct symbol *framefunc, CORE_ADDR pc, const gdb_byte **start, size_t *length) |
| static CORE_ADDR | locexpr_get_frame_base (struct symbol *framefunc, struct frame_info *frame) |
| static void | loclist_find_frame_base_location (struct symbol *framefunc, CORE_ADDR pc, const gdb_byte **start, size_t *length) |
| static CORE_ADDR | loclist_get_frame_base (struct symbol *framefunc, struct frame_info *frame) |
| void | func_get_frame_base_dwarf_block (struct symbol *framefunc, CORE_ADDR pc, const gdb_byte **start, size_t *length) |
| static CORE_ADDR | get_frame_pc_for_per_cu_dwarf_call (void *baton) |
| static void | per_cu_dwarf_call (struct dwarf_expr_context *ctx, cu_offset die_offset, struct dwarf2_per_cu_data *per_cu) |
| static void | show_entry_values_debug (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
| static CORE_ADDR | call_site_to_target_addr (struct gdbarch *call_site_gdbarch, struct call_site *call_site, struct frame_info *caller_frame) |
| static struct symbol * | func_addr_to_tail_call_list (struct gdbarch *gdbarch, CORE_ADDR addr) |
| static void | func_verify_no_selftailcall (struct gdbarch *gdbarch, CORE_ADDR verify_addr) |
| static void | tailcall_dump (struct gdbarch *gdbarch, const struct call_site *call_site) |
| static void | chain_candidate (struct gdbarch *gdbarch, gdb::unique_xmalloc_ptr< struct call_site_chain > *resultp, std::vector< struct call_site *> *chain) |
| static struct call_site_chain * | call_site_find_chain_1 (struct gdbarch *gdbarch, CORE_ADDR caller_pc, CORE_ADDR callee_pc) |
| struct call_site_chain * | call_site_find_chain (struct gdbarch *gdbarch, CORE_ADDR caller_pc, CORE_ADDR callee_pc) |
| static int | call_site_parameter_matches (struct call_site_parameter *parameter, enum call_site_parameter_kind kind, union call_site_parameter_u kind_u) |
| static struct value * | dwarf_entry_parameter_to_value (struct call_site_parameter *parameter, CORE_ADDR deref_size, struct type *type, struct frame_info *caller_frame, struct dwarf2_per_cu_data *per_cu) |
| static struct value * | entry_data_value_coerce_ref (const struct value *value) |
| static void * | entry_data_value_copy_closure (const struct value *v) |
| static void | entry_data_value_free_closure (struct value *v) |
| static struct value * | value_of_dwarf_reg_entry (struct type *type, struct frame_info *frame, enum call_site_parameter_kind kind, union call_site_parameter_u kind_u) |
| static struct value * | value_of_dwarf_block_entry (struct type *type, struct frame_info *frame, const gdb_byte *block, size_t block_len) |
| static struct piece_closure * | allocate_piece_closure (struct dwarf2_per_cu_data *per_cu, std::vector< dwarf_expr_piece > &&pieces, struct frame_info *frame) |
| static void | copy_bitwise (gdb_byte *dest, ULONGEST dest_offset, const gdb_byte *source, ULONGEST source_offset, ULONGEST nbits, int bits_big_endian) |
| static size_t | bits_to_bytes (ULONGEST start, ULONGEST n_bits) |
| static void | rw_pieced_value (struct value *v, struct value *from) |
| static void | read_pieced_value (struct value *v) |
| static void | write_pieced_value (struct value *to, struct value *from) |
| static int | check_pieced_synthetic_pointer (const struct value *value, LONGEST bit_offset, int bit_length) |
| static CORE_ADDR | get_frame_address_in_block_wrapper (void *baton) |
| static struct value * | fetch_const_value_from_synthetic_pointer (sect_offset die, LONGEST byte_offset, struct dwarf2_per_cu_data *per_cu, struct type *type) |
| static struct value * | indirect_synthetic_pointer (sect_offset die, LONGEST byte_offset, struct dwarf2_per_cu_data *per_cu, struct frame_info *frame, struct type *type) |
| static struct value * | indirect_pieced_value (struct value *value) |
| static struct value * | coerce_pieced_ref (const struct value *value) |
| static void * | copy_pieced_value_closure (const struct value *v) |
| static void | free_pieced_value_closure (struct value *v) |
| struct value * | dwarf2_evaluate_loc_desc (struct type *type, struct frame_info *frame, const gdb_byte *data, size_t size, struct dwarf2_per_cu_data *per_cu) |
| static int | dwarf2_locexpr_baton_eval (const struct dwarf2_locexpr_baton *dlbaton, struct frame_info *frame, CORE_ADDR addr, CORE_ADDR *valp) |
| int | dwarf2_evaluate_property (const struct dynamic_prop *prop, struct frame_info *frame, struct property_addr_info *addr_stack, CORE_ADDR *value) |
| void | dwarf2_compile_property_to_c (string_file &stream, const char *result_name, struct gdbarch *gdbarch, unsigned char *registers_used, const struct dynamic_prop *prop, CORE_ADDR pc, struct symbol *sym) |
| static enum symbol_needs_kind | dwarf2_loc_desc_get_symbol_read_needs (const gdb_byte *data, size_t size, struct dwarf2_per_cu_data *per_cu) |
| static void | unimplemented (unsigned int op) |
| int | dwarf_reg_to_regnum (struct gdbarch *arch, int dwarf_reg) |
| static void | throw_bad_regnum_error (ULONGEST dwarf_reg) |
| int | dwarf_reg_to_regnum_or_error (struct gdbarch *arch, ULONGEST dwarf_reg) |
| static void | access_memory (struct gdbarch *arch, struct agent_expr *expr, ULONGEST nbits) |
| static CORE_ADDR | get_ax_pc (void *baton) |
| void | dwarf2_compile_expr_to_ax (struct agent_expr *expr, struct axs_value *loc, unsigned int addr_size, const gdb_byte *op_ptr, const gdb_byte *op_end, struct dwarf2_per_cu_data *per_cu) |
| static struct value * | locexpr_read_variable (struct symbol *symbol, struct frame_info *frame) |
| static struct value * | locexpr_read_variable_at_entry (struct symbol *symbol, struct frame_info *frame) |
| static enum symbol_needs_kind | locexpr_get_symbol_read_needs (struct symbol *symbol) |
| static int | piece_end_p (const gdb_byte *data, const gdb_byte *end) |
| static const char * | locexpr_regname (struct gdbarch *gdbarch, int dwarf_regnum) |
| static const gdb_byte * | locexpr_describe_location_piece (struct symbol *symbol, struct ui_file *stream, CORE_ADDR addr, struct objfile *objfile, struct dwarf2_per_cu_data *per_cu, const gdb_byte *data, const gdb_byte *end, unsigned int addr_size) |
| static const gdb_byte * | disassemble_dwarf_expression (struct ui_file *stream, struct gdbarch *arch, unsigned int addr_size, int offset_size, const gdb_byte *start, const gdb_byte *data, const gdb_byte *end, int indent, int all, struct dwarf2_per_cu_data *per_cu) |
| static void | locexpr_describe_location_1 (struct symbol *symbol, CORE_ADDR addr, struct ui_file *stream, const gdb_byte *data, size_t size, struct objfile *objfile, unsigned int addr_size, int offset_size, struct dwarf2_per_cu_data *per_cu) |
| static void | locexpr_describe_location (struct symbol *symbol, CORE_ADDR addr, struct ui_file *stream) |
| static void | locexpr_tracepoint_var_ref (struct symbol *symbol, struct agent_expr *ax, struct axs_value *value) |
| static void | locexpr_generate_c_location (struct symbol *sym, string_file &stream, struct gdbarch *gdbarch, unsigned char *registers_used, CORE_ADDR pc, const char *result_name) |
| static struct value * | loclist_read_variable (struct symbol *symbol, struct frame_info *frame) |
| static struct value * | loclist_read_variable_at_entry (struct symbol *symbol, struct frame_info *frame) |
| static enum symbol_needs_kind | loclist_symbol_needs (struct symbol *symbol) |
| static void | loclist_describe_location (struct symbol *symbol, CORE_ADDR addr, struct ui_file *stream) |
| static void | loclist_tracepoint_var_ref (struct symbol *symbol, struct agent_expr *ax, struct axs_value *value) |
| static void | loclist_generate_c_location (struct symbol *sym, string_file &stream, struct gdbarch *gdbarch, unsigned char *registers_used, CORE_ADDR pc, const char *result_name) |
| void | _initialize_dwarf2loc (void) |
Variables | |
| int | dwarf_always_disassemble |
| const struct symbol_block_ops | dwarf2_block_frame_base_locexpr_funcs |
| const struct symbol_block_ops | dwarf2_block_frame_base_loclist_funcs |
| unsigned int | entry_values_debug = 0 |
| static const struct lval_funcs | entry_data_value_funcs |
| static const struct lval_funcs | pieced_value_funcs |
| const struct symbol_computed_ops | dwarf2_locexpr_funcs |
| const struct symbol_computed_ops | dwarf2_loclist_funcs |
| enum debug_loc_kind |
| Enumerator | |
|---|---|
| DEBUG_LOC_END_OF_LIST | |
| DEBUG_LOC_BASE_ADDRESS | |
| DEBUG_LOC_START_END | |
| DEBUG_LOC_START_LENGTH | |
| DEBUG_LOC_BUFFER_OVERFLOW | |
| DEBUG_LOC_INVALID_ENTRY | |
Definition at line 69 of file dwarf2loc.c.
| void _initialize_dwarf2loc | ( | void | ) |
Definition at line 4652 of file dwarf2loc.c.
References _, add_setshow_zuinteger_cmd(), class_maintenance, entry_values_debug, selftests::register_test(), setdebuglist, show_entry_values_debug(), and showdebuglist.
|
static |
Definition at line 2941 of file dwarf2loc.c.
References ax_const_l(), ax_simple(), ax_trace_quick(), ax_zero_ext(), gdb_assert, gdbarch_bits_big_endian(), and agent_expr::tracing.
Referenced by dwarf2_compile_expr_to_ax().
|
static |
Definition at line 1499 of file dwarf2loc.c.
References DWARF_VALUE_STACK, piece_closure::frame_id, get_frame_id(), dwarf_expr_piece::location, null_frame_id, piece_closure::per_cu, piece_closure::pieces, piece_closure::refc, dwarf_expr_piece::v, dwarf_expr_piece::value, and value_incref().
Referenced by dwarf2_evaluate_loc_desc_full().
Definition at line 1754 of file dwarf2loc.c.
Referenced by rw_pieced_value().
| struct call_site_chain* call_site_find_chain | ( | struct gdbarch * | gdbarch, |
| CORE_ADDR | caller_pc, | ||
| CORE_ADDR | callee_pc | ||
| ) |
Definition at line 1155 of file dwarf2loc.c.
References call_site_find_chain_1(), CATCH, END_CATCH, entry_values_debug, exception_print(), gdb_stdout, NO_ENTRY_VALUE_ERROR, RETURN_MASK_ERROR, throw_exception(), and TRY.
Referenced by dwarf2_tailcall_sniffer_first().
|
static |
Definition at line 1032 of file dwarf2loc.c.
References _, call_site_for_pc(), call_site_to_target_addr(), chain_candidate(), func_addr_to_tail_call_list(), gdb_assert, get_pc_function_start(), lookup_minimal_symbol_by_pc(), bound_minimal_symbol::minsym, MSYMBOL_PRINT_NAME, NO_ENTRY_VALUE_ERROR, paddress(), call_site::pc, SYMBOL_TYPE, call_site::tail_call_next, throw_error(), and TYPE_TAIL_CALL_LIST.
Referenced by call_site_find_chain().
|
static |
Definition at line 1184 of file dwarf2loc.c.
References CALL_SITE_PARAMETER_DWARF_REG, CALL_SITE_PARAMETER_FB_OFFSET, CALL_SITE_PARAMETER_PARAM_OFFSET, call_site_parameter_u::dwarf_reg, call_site_parameter_u::fb_offset, call_site_parameter::kind, call_site_parameter_u::param_cu_off, and call_site_parameter::u.
Referenced by dwarf_expr_reg_to_entry_parameter().
|
static |
Definition at line 743 of file dwarf2loc.c.
References _, BMSYMBOL_VALUE_ADDRESS, builtin_type::builtin_func_ptr, builtin_type(), dwarf_block::data, dwarf2_evaluate_loc_desc(), FIELD_DWARF_BLOCK, FIELD_LOC_KIND, FIELD_LOC_KIND_DWARF_BLOCK, FIELD_LOC_KIND_PHYSADDR, FIELD_LOC_KIND_PHYSNAME, FIELD_STATIC_PHYSADDR, FIELD_STATIC_PHYSNAME, get_frame_arch(), internal_error(), lookup_minimal_symbol(), lookup_minimal_symbol_by_pc(), lval_memory, bound_minimal_symbol::minsym, MSYMBOL_PRINT_NAME, NO_ENTRY_VALUE_ERROR, paddress(), call_site::pc, dwarf_block::size, call_site::target, throw_error(), value_address(), value_as_address(), and VALUE_LVAL.
Referenced by call_site_find_chain_1(), dwarf_expr_reg_to_entry_parameter(), and func_verify_no_selftailcall().
|
static |
Definition at line 933 of file dwarf2loc.c.
References call_site_chain::call_site, call_site_chain::callees, call_site_chain::callers, entry_values_debug, fprintf_unfiltered(), fputc_unfiltered(), fputs_unfiltered(), gdb_assert, gdb_stdlog, call_site_chain::length, tailcall_dump(), and xmalloc().
Referenced by call_site_find_chain_1().
|
static |
Definition at line 2065 of file dwarf2loc.c.
References DWARF_VALUE_IMPLICIT_POINTER, dwarf_expr_piece::location, piece_closure::pieces, dwarf_expr_piece::size, value_bitpos(), value_bitsize(), value_computed_closure(), and value_offset().
Definition at line 2252 of file dwarf2loc.c.
References _, check_typedef(), gdb_assert, get_selected_frame(), indirect_synthetic_pointer(), piece_closure::per_cu, piece_closure::pieces, TARGET_CHAR_BIT, TYPE_LENGTH, value_bits_synthetic_pointer(), value_computed_closure(), value_embedded_offset(), and value_type().
|
static |
Definition at line 1525 of file dwarf2loc.c.
Referenced by rw_pieced_value().
|
static |
Definition at line 2282 of file dwarf2loc.c.
References piece_closure::refc, and value_computed_closure().
|
static |
Definition at line 112 of file dwarf2loc.c.
References DEBUG_LOC_BASE_ADDRESS, DEBUG_LOC_BUFFER_OVERFLOW, DEBUG_LOC_END_OF_LIST, DEBUG_LOC_START_END, extract_signed_integer(), and extract_unsigned_integer().
Referenced by dwarf2_find_location_expression(), and loclist_describe_location().
|
static |
Definition at line 206 of file dwarf2loc.c.
References DEBUG_LOC_BASE_ADDRESS, DEBUG_LOC_BUFFER_OVERFLOW, DEBUG_LOC_END_OF_LIST, DEBUG_LOC_INVALID_ENTRY, DEBUG_LOC_START_END, DEBUG_LOC_START_LENGTH, dwarf2_read_addr_index(), extract_unsigned_integer(), and gdb_read_uleb128().
Referenced by dwarf2_find_location_expression(), and loclist_describe_location().
|
static |
Definition at line 155 of file dwarf2loc.c.
References DEBUG_LOC_BASE_ADDRESS, DEBUG_LOC_BUFFER_OVERFLOW, DEBUG_LOC_END_OF_LIST, DEBUG_LOC_INVALID_ENTRY, DEBUG_LOC_START_END, extract_signed_integer(), extract_unsigned_integer(), and gdb_read_uleb128().
Referenced by dwarf2_find_location_expression().
|
static |
Definition at line 3909 of file dwarf2loc.c.
References _, all, symbol::arch, dwarf2_get_die_type(), dwarf2_read_addr_index(), error(), extract_signed_integer(), extract_unsigned_integer(), fprintf_filtered(), fputc_filtered(), gdbarch_byte_order(), locexpr_regname(), name, offset, phex_nz(), plongest(), pulongest(), safe_read_sleb128(), safe_read_uleb128(), to_underlying(), type, and type_print().
Referenced by locexpr_describe_location_1().
| void dwarf2_compile_expr_to_ax | ( | struct agent_expr * | expr, |
| struct axs_value * | loc, | ||
| unsigned int | addr_size, | ||
| const gdb_byte * | op_ptr, | ||
| const gdb_byte * | op_end, | ||
| struct dwarf2_per_cu_data * | per_cu | ||
| ) |
Definition at line 3001 of file dwarf2loc.c.
References _, access_memory(), symbol::arch, ax_const_l(), ax_ext(), ax_goto(), ax_label(), ax_pick(), ax_reg(), ax_simple(), ax_zero_ext(), axs_lvalue_memory, axs_lvalue_register, axs_rvalue, block_for_pc(), block_linkage_function(), dwarf2_compile_expr_to_ax(), dwarf2_fetch_cfa_info(), dwarf2_fetch_die_loc_cu_off(), dwarf2_per_cu_text_offset(), dwarf_expr_require_composition(), dwarf_reg_to_regnum_or_error(), error(), extract_signed_integer(), extract_unsigned_integer(), func_get_frame_base_dwarf_block(), gdb_assert, agent_expr::gdbarch, gdbarch_bits_big_endian(), gdbarch_byte_order(), get_ax_pc(), internal_error(), agent_expr::len, loc, offset, dwarf2_locexpr_baton::per_cu, regnum, require_rvalue(), safe_read_sleb128(), safe_read_uleb128(), agent_expr::scope, size, TARGET_CHAR_BIT, and unimplemented().
Referenced by dwarf2_compile_expr_to_ax(), locexpr_tracepoint_var_ref(), and loclist_tracepoint_var_ref().
| void dwarf2_compile_property_to_c | ( | string_file & | stream, |
| const char * | result_name, | ||
| struct gdbarch * | gdbarch, | ||
| unsigned char * | registers_used, | ||
| const struct dynamic_prop * | prop, | ||
| CORE_ADDR | pc, | ||
| struct symbol * | sym | ||
| ) |
Definition at line 2694 of file dwarf2loc.c.
References dynamic_prop_data::baton, compile_dwarf_bounds_to_c(), dwarf2_locexpr_baton::data, dynamic_prop::data, dwarf2_find_location_expression(), dwarf2_per_cu_addr_size(), gdb_assert, if(), dynamic_prop::kind, dwarf2_property_baton::locexpr, dwarf2_property_baton::loclist, dwarf2_locexpr_baton::per_cu, dwarf2_loclist_baton::per_cu, PROP_LOCEXPR, PROP_LOCLIST, dwarf2_locexpr_baton::size, and size.
Referenced by generate_vla_size().
| struct value* dwarf2_evaluate_loc_desc | ( | struct type * | type, |
| struct frame_info * | frame, | ||
| const gdb_byte * | data, | ||
| size_t | size, | ||
| struct dwarf2_per_cu_data * | per_cu | ||
| ) |
Definition at line 2539 of file dwarf2loc.c.
References dwarf2_evaluate_loc_desc_full(), and size.
Referenced by call_site_to_target_addr(), dwarf2_compute_name(), dwarf2_evaluate_property(), dwarf_entry_parameter_to_value(), locexpr_get_frame_base(), locexpr_read_variable(), loclist_get_frame_base(), and loclist_read_variable().
|
static |
Definition at line 2326 of file dwarf2loc.c.
References _, dwarf_expr_context::addr_size, allocate_computed_value(), allocate_optimized_out_value(), allocate_piece_closure(), allocate_value(), builtin_type::builtin_data_ptr, builtin_type::builtin_func_ptr, builtin_type(), CATCH, dwarf_expr_context::data, dwarf2_per_cu_addr_size(), dwarf2_per_cu_objfile(), dwarf2_per_cu_ref_addr_size(), dwarf2_per_cu_text_offset(), dwarf_reg_to_regnum_or_error(), DWARF_VALUE_IMPLICIT_POINTER, DWARF_VALUE_LITERAL, DWARF_VALUE_MEMORY, DWARF_VALUE_OPTIMIZED_OUT, DWARF_VALUE_REGISTER, DWARF_VALUE_STACK, END_CATCH, entry_values_debug, error(), dwarf_expr_context::eval(), exception_print(), dwarf_expr_context::fetch(), dwarf_expr_context::fetch_address(), dwarf_expr_context::fetch_in_stack_memory(), dwarf_evaluate_loc_desc::frame, scoped_value_mark::free_to_mark(), gdb_stdout, dwarf_expr_context::gdbarch, gdbarch_byte_order(), get_frame_arch(), get_objfile_arch(), dwarf_expr_context::initialized, internal_error(), invalid_synthetic_pointer(), dwarf_expr_context::len, dwarf_expr_context::location, longest_to_int(), mark_value_bytes_unavailable(), NO_ENTRY_VALUE_ERROR, NOT_AVAILABLE_ERROR, dwarf_evaluate_loc_desc::obj_address, dwarf_expr_context::offset, dwarf_evaluate_loc_desc::per_cu, piece_closure::per_cu, pieced_value_funcs, dwarf_expr_context::pieces, dwarf_expr_context::ref_addr_size, RETURN_MASK_ERROR, set_value_initialized(), set_value_offset(), set_value_stack(), dwarf_expr_piece::size, size, throw_exception(), TRY, type, TYPE_CODE, TYPE_CODE_FUNC, TYPE_CODE_METHOD, TYPE_LENGTH, value_as_address(), value_as_long(), value_at_lazy(), value_contents_all(), value_contents_copy(), value_contents_raw(), value_from_pointer(), value_from_register(), value_incref(), value_optimized_out(), and value_type().
Referenced by dwarf2_evaluate_loc_desc(), and indirect_synthetic_pointer().
| int dwarf2_evaluate_property | ( | const struct dynamic_prop * | prop, |
| struct frame_info * | frame, | ||
| struct property_addr_info * | addr_stack, | ||
| CORE_ADDR * | value | ||
| ) |
Definition at line 2604 of file dwarf2loc.c.
References _, property_addr_info::addr, dynamic_prop_data::baton, dynamic_prop_data::const_val, dynamic_prop::data, dwarf2_evaluate_loc_desc(), dwarf2_find_location_expression(), dwarf2_locexpr_baton_eval(), error(), get_frame_address_in_block(), get_selected_frame(), has_stack_frames(), if(), dynamic_prop::kind, dwarf2_property_baton::locexpr, dwarf2_property_baton::loclist, property_addr_info::next, dwarf2_offset_baton::offset, dwarf2_property_baton::offset_info, dwarf2_loclist_baton::per_cu, PROP_ADDR_OFFSET, PROP_CONST, PROP_LOCEXPR, PROP_LOCLIST, dwarf2_property_baton::referenced_type, size, dwarf2_offset_baton::type, value_as_address(), value_at(), value_from_contents(), and value_optimized_out().
Referenced by follow_static_link(), resolve_dynamic_array(), resolve_dynamic_range(), and resolve_dynamic_type_internal().
| const gdb_byte* dwarf2_find_location_expression | ( | struct dwarf2_loclist_baton * | baton, |
| size_t * | locexpr_length, | ||
| CORE_ADDR | pc | ||
| ) |
Definition at line 267 of file dwarf2loc.c.
References _, dwarf2_loclist_baton::base_address, block_for_pc(), block_linkage_function(), BLOCK_START, gdbarch::byte_order, dwarf2_loclist_baton::data, DEBUG_LOC_BASE_ADDRESS, DEBUG_LOC_BUFFER_OVERFLOW, DEBUG_LOC_END_OF_LIST, DEBUG_LOC_INVALID_ENTRY, DEBUG_LOC_START_END, DEBUG_LOC_START_LENGTH, decode_debug_loc_addresses(), decode_debug_loc_dwo_addresses(), decode_debug_loclists_addresses(), dwarf2_per_cu_addr_size(), dwarf2_per_cu_objfile(), dwarf2_per_cu_text_offset(), dwarf2_version(), error(), extract_unsigned_integer(), dwarf2_loclist_baton::from_dwo, gdb_assert_not_reached, gdbarch_byte_order(), get_objfile_arch(), objfile::obfd, dwarf2_loclist_baton::per_cu, read_unsigned_leb128(), dwarf2_loclist_baton::size, and SYMBOL_BLOCK_VALUE.
Referenced by dwarf2_compile_property_to_c(), dwarf2_evaluate_property(), dwarf2_fetch_die_loc_sect_off(), loclist_find_frame_base_location(), loclist_generate_c_location(), loclist_read_variable(), loclist_read_variable_at_entry(), and loclist_tracepoint_var_ref().
|
static |
Definition at line 2834 of file dwarf2loc.c.
References dwarf_expr_context::addr_size, dwarf2_per_cu_addr_size(), dwarf2_per_cu_objfile(), dwarf2_per_cu_ref_addr_size(), dwarf2_per_cu_text_offset(), DWARF_VALUE_REGISTER, dwarf_expr_context::eval(), dwarf_expr_context::gdbarch, get_objfile_arch(), dwarf_expr_context::location, dwarf_expr_piece::location, symbol_needs_eval_context::needs, dwarf_expr_context::offset, symbol_needs_eval_context::per_cu, dwarf_expr_context::pieces, dwarf_expr_context::ref_addr_size, size, SYMBOL_NEEDS_FRAME, and SYMBOL_NEEDS_NONE.
Referenced by locexpr_get_symbol_read_needs().
|
static |
Definition at line 2554 of file dwarf2loc.c.
References dwarf_expr_context::addr_size, dwarf_expr_context::data, dwarf2_locexpr_baton::data, dwarf2_per_cu_addr_size(), dwarf2_per_cu_objfile(), dwarf2_per_cu_ref_addr_size(), dwarf2_per_cu_text_offset(), DWARF_VALUE_IMPLICIT_POINTER, DWARF_VALUE_LITERAL, DWARF_VALUE_MEMORY, DWARF_VALUE_OPTIMIZED_OUT, DWARF_VALUE_REGISTER, DWARF_VALUE_STACK, dwarf_expr_context::eval(), extract_signed_integer(), dwarf_expr_context::fetch_address(), dwarf_evaluate_loc_desc::frame, dwarf_expr_context::gdbarch, gdbarch_byte_order(), get_objfile_arch(), dwarf_expr_context::len, dwarf_expr_context::location, dwarf_evaluate_loc_desc::obj_address, objfile::objfile(), dwarf_expr_context::offset, dwarf2_locexpr_baton::per_cu, dwarf_evaluate_loc_desc::per_cu, dwarf_evaluate_loc_desc::read_addr_from_reg(), dwarf_expr_context::ref_addr_size, and dwarf2_locexpr_baton::size.
Referenced by dwarf2_evaluate_property().
|
static |
Definition at line 1316 of file dwarf2loc.c.
References _, call_site_parameter::data_value, call_site_parameter::data_value_size, dwarf2_evaluate_loc_desc(), NO_ENTRY_VALUE_ERROR, size, throw_error(), call_site_parameter::value, and call_site_parameter::value_size.
Referenced by value_of_dwarf_reg_entry().
|
static |
Definition at line 1208 of file dwarf2loc.c.
References _, call_site_for_pc(), call_site_parameter_matches(), call_site_to_target_addr(), frame_unwind_arch(), func_verify_no_selftailcall(), gdb_assert, gdbarch_bfd_arch_info(), get_frame_arch(), get_frame_func(), get_frame_pc(), get_frame_type(), get_prev_frame(), INLINE_FRAME, lookup_minimal_symbol_by_pc(), bound_minimal_symbol::minsym, MSYMBOL_PRINT_NAME, NO_ENTRY_VALUE_ERROR, paddress(), call_site::parameter, call_site::parameter_count, call_site::per_cu, and throw_error().
Referenced by dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value(), and value_of_dwarf_reg_entry().
| int dwarf_reg_to_regnum | ( | struct gdbarch * | arch, |
| int | dwarf_reg | ||
| ) |
Definition at line 2890 of file dwarf2loc.c.
References _, complaint, gdbarch_dwarf2_reg_to_regnum(), and symfile_complaints.
Referenced by dwarf2_frame_cache(), dwarf2_restore_rule(), dwarf_block_to_sp_offset(), dwarf_reg_to_regnum_or_error(), and locexpr_regname().
Definition at line 2920 of file dwarf2loc.c.
References dwarf_reg_to_regnum(), INT_MAX, and throw_bad_regnum_error().
Referenced by do_compile_dwarf_expr_to_c(), dwarf2_compile_expr_to_ax(), dwarf2_evaluate_loc_desc_full(), dwarf2_fetch_cfa_info(), dwarf2_frame_prev_register(), dwarf_expr_executor::get_reg_value(), dwarf_evaluate_loc_desc::get_reg_value(), read_addr_from_reg(), dwarf_evaluate_loc_desc::read_addr_from_reg(), and rw_pieced_value().
Definition at line 1348 of file dwarf2loc.c.
References check_typedef(), TYPE_IS_REFERENCE, value_computed_closure(), value_incref(), and value_type().
|
static |
Definition at line 1364 of file dwarf2loc.c.
References value_computed_closure(), and value_incref().
|
static |
Definition at line 1375 of file dwarf2loc.c.
References value_computed_closure(), and value_free().
|
static |
Definition at line 2113 of file dwarf2loc.c.
References allocate_optimized_out_value(), dwarf2_fetch_constant_bytes(), invalid_synthetic_pointer(), TYPE_LENGTH, TYPE_TARGET_TYPE, and value_from_contents().
Referenced by indirect_synthetic_pointer().
|
static |
Definition at line 2292 of file dwarf2loc.c.
References DWARF_VALUE_STACK, dwarf_expr_piece::location, piece_closure::pieces, piece_closure::refc, dwarf_expr_piece::v, dwarf_expr_piece::value, value_computed_closure(), and value_free().
|
static |
Definition at line 831 of file dwarf2loc.c.
References _, BLOCK_START, find_pc_function(), gdb_assert, NO_ENTRY_VALUE_ERROR, paddress(), SYMBOL_BLOCK_VALUE, SYMBOL_TYPE, throw_error(), type, TYPE_CODE, TYPE_CODE_FUNC, TYPE_SPECIFIC_FIELD, and TYPE_SPECIFIC_FUNC.
Referenced by call_site_find_chain_1(), and func_verify_no_selftailcall().
| void func_get_frame_base_dwarf_block | ( | struct symbol * | framefunc, |
| CORE_ADDR | pc, | ||
| const gdb_byte ** | start, | ||
| size_t * | length | ||
| ) |
Definition at line 508 of file dwarf2loc.c.
References _, error(), symbol_block_ops::find_frame_base_location, SYMBOL_BLOCK_OPS, and SYMBOL_NATURAL_NAME.
Referenced by do_compile_dwarf_expr_to_c(), dwarf2_compile_expr_to_ax(), dwarf_evaluate_loc_desc::get_frame_base(), and locexpr_describe_location_piece().
Definition at line 859 of file dwarf2loc.c.
References _, call_site_to_target_addr(), func_addr_to_tail_call_list(), lookup_minimal_symbol_by_pc(), MSYMBOL_PRINT_NAME, NO_ENTRY_VALUE_ERROR, paddress(), SYMBOL_TYPE, call_site::tail_call_next, throw_error(), and TYPE_TAIL_CALL_LIST.
Referenced by dwarf_expr_reg_to_entry_parameter().
|
static |
Definition at line 2980 of file dwarf2loc.c.
References agent_expr::scope.
Referenced by dwarf2_compile_expr_to_ax().
|
static |
Definition at line 2105 of file dwarf2loc.c.
References get_frame_address_in_block().
Referenced by indirect_synthetic_pointer().
|
static |
Definition at line 526 of file dwarf2loc.c.
References dwarf_expr_context::get_frame_pc().
Referenced by per_cu_dwarf_call().
Definition at line 2175 of file dwarf2loc.c.
References _, check_typedef(), DWARF_VALUE_IMPLICIT_POINTER, error(), extract_signed_integer(), gdb_assert, gdbarch_byte_order(), get_frame_arch(), get_selected_frame(), indirect_synthetic_pointer(), dwarf_expr_piece::location, piece_closure::per_cu, piece_closure::pieces, dwarf_expr_piece::ptr, dwarf_expr_piece::size, type, TYPE_CODE, TYPE_CODE_PTR, TYPE_LENGTH, dwarf_expr_piece::v, value_bitpos(), value_bitsize(), value_computed_closure(), value_contents(), value_offset(), and value_type().
|
static |
Definition at line 2144 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_evaluate_loc_desc_full(), dwarf2_fetch_die_loc_sect_off(), dwarf2_fetch_die_type_sect_off(), fetch_const_value_from_synthetic_pointer(), get_frame_address_in_block_wrapper(), invalid_synthetic_pointer(), dwarf2_locexpr_baton::per_cu, dwarf2_locexpr_baton::size, and TYPE_TARGET_TYPE.
Referenced by coerce_pieced_ref(), and indirect_pieced_value().
|
static |
Definition at line 100 of file dwarf2loc.c.
Referenced by dwarf2_evaluate_loc_desc_full(), fetch_const_value_from_synthetic_pointer(), and indirect_synthetic_pointer().
|
static |
Definition at line 4372 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_per_cu_addr_size(), dwarf2_per_cu_objfile(), dwarf2_per_cu_offset_size(), locexpr_describe_location_1(), dwarf2_locexpr_baton::per_cu, dwarf2_locexpr_baton::size, and SYMBOL_LOCATION_BATON.
|
static |
Definition at line 4278 of file dwarf2loc.c.
References _, bits, disassemble_dwarf_expression(), dwarf_always_disassemble, error(), fprintf_filtered(), get_objfile_arch(), locexpr_describe_location_piece(), offset, pulongest(), safe_read_uleb128(), size, and SYMBOL_PRINT_NAME.
Referenced by locexpr_describe_location(), and loclist_describe_location().
|
static |
Definition at line 3737 of file dwarf2loc.c.
References _, block_for_pc(), block_linkage_function(), gdbarch::data, dwarf2_read_addr_index(), error(), extract_unsigned_integer(), fprintf_filtered(), func_get_frame_base_dwarf_block(), gdbarch_byte_order(), get_objfile_arch(), leb128_size(), locexpr_regname(), objfile_name(), offset, phex_nz(), piece_end_p(), plongest(), safe_read_sleb128(), safe_read_uleb128(), and SYMBOL_PRINT_NAME.
Referenced by locexpr_describe_location_1().
|
static |
Definition at line 394 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_locexpr_baton::size, and SYMBOL_LOCATION_BATON.
|
static |
Definition at line 4408 of file dwarf2loc.c.
References _, compile_dwarf_expr_to_c(), dwarf2_locexpr_baton::data, dwarf2_per_cu_addr_size(), error(), dwarf2_locexpr_baton::per_cu, dwarf2_locexpr_baton::size, SYMBOL_LOCATION_BATON, and SYMBOL_NATURAL_NAME.
|
static |
Definition at line 408 of file dwarf2loc.c.
References builtin_type::builtin_data_ptr, builtin_type(), dwarf2_evaluate_loc_desc(), gdb_assert, get_frame_arch(), get_frame_pc(), dwarf2_locexpr_baton::per_cu, SYMBOL_BLOCK_OPS, SYMBOL_LOCATION_BATON, type, and value_address().
|
static |
Definition at line 3690 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_loc_desc_get_symbol_read_needs(), dwarf2_locexpr_baton::per_cu, dwarf2_locexpr_baton::size, and SYMBOL_LOCATION_BATON.
|
static |
Definition at line 3660 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_evaluate_loc_desc(), dwarf2_locexpr_baton::per_cu, dwarf2_locexpr_baton::size, SYMBOL_LOCATION_BATON, and SYMBOL_TYPE.
|
static |
Definition at line 3677 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_locexpr_baton::size, SYMBOL_LOCATION_BATON, SYMBOL_TYPE, and value_of_dwarf_block_entry().
|
static |
Definition at line 3712 of file dwarf2loc.c.
References _, dwarf_reg_to_regnum(), gdbarch_register_name(), and regnum.
Referenced by disassemble_dwarf_expression(), and locexpr_describe_location_piece().
|
static |
Definition at line 4391 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data, dwarf2_compile_expr_to_ax(), dwarf2_per_cu_addr_size(), dwarf2_locexpr_baton::per_cu, dwarf2_locexpr_baton::size, and SYMBOL_LOCATION_BATON.
|
static |
Definition at line 4508 of file dwarf2loc.c.
References _, dwarf2_loclist_baton::base_address, gdbarch::byte_order, dwarf2_loclist_baton::data, DEBUG_LOC_BASE_ADDRESS, DEBUG_LOC_BUFFER_OVERFLOW, DEBUG_LOC_END_OF_LIST, DEBUG_LOC_INVALID_ENTRY, DEBUG_LOC_START_END, DEBUG_LOC_START_LENGTH, decode_debug_loc_addresses(), decode_debug_loc_dwo_addresses(), dwarf2_per_cu_addr_size(), dwarf2_per_cu_objfile(), dwarf2_per_cu_offset_size(), dwarf2_per_cu_text_offset(), error(), extract_unsigned_integer(), fprintf_filtered(), dwarf2_loclist_baton::from_dwo, gdb_assert_not_reached, gdbarch_adjust_dwarf2_addr(), gdbarch_byte_order(), get_objfile_arch(), locexpr_describe_location_1(), objfile::obfd, paddress(), dwarf2_loclist_baton::per_cu, dwarf2_loclist_baton::size, SYMBOL_LOCATION_BATON, and SYMBOL_PRINT_NAME.
|
static |
Definition at line 452 of file dwarf2loc.c.
References dwarf2_find_location_expression(), and SYMBOL_LOCATION_BATON.
|
static |
Definition at line 4618 of file dwarf2loc.c.
References _, compile_dwarf_expr_to_c(), dwarf2_loclist_baton::data, dwarf2_find_location_expression(), dwarf2_per_cu_addr_size(), error(), dwarf2_loclist_baton::per_cu, size, SYMBOL_LOCATION_BATON, and SYMBOL_NATURAL_NAME.
|
static |
Definition at line 465 of file dwarf2loc.c.
References builtin_type::builtin_data_ptr, builtin_type(), dwarf2_evaluate_loc_desc(), gdb_assert, get_frame_arch(), get_frame_pc(), dwarf2_loclist_baton::per_cu, SYMBOL_BLOCK_OPS, SYMBOL_LOCATION_BATON, type, and value_address().
|
static |
Definition at line 4445 of file dwarf2loc.c.
References dwarf2_evaluate_loc_desc(), dwarf2_find_location_expression(), get_frame_address_in_block(), dwarf2_loclist_baton::per_cu, size, SYMBOL_LOCATION_BATON, and SYMBOL_TYPE.
|
static |
Definition at line 4470 of file dwarf2loc.c.
References allocate_optimized_out_value(), dwarf2_loclist_baton::data, dwarf2_find_location_expression(), get_frame_func_if_available(), size, SYMBOL_LOCATION_BATON, SYMBOL_TYPE, and value_of_dwarf_block_entry().
|
static |
Definition at line 4492 of file dwarf2loc.c.
References SYMBOL_NEEDS_FRAME.
|
static |
Definition at line 4598 of file dwarf2loc.c.
References dwarf2_loclist_baton::data, dwarf2_compile_expr_to_ax(), dwarf2_find_location_expression(), dwarf2_per_cu_addr_size(), dwarf2_loclist_baton::per_cu, agent_expr::scope, size, and SYMBOL_LOCATION_BATON.
|
static |
Definition at line 534 of file dwarf2loc.c.
References dwarf2_fetch_die_loc_cu_off(), dwarf_expr_context::eval(), gdb_assert, get_frame_pc_for_per_cu_dwarf_call(), and dwarf2_locexpr_baton::per_cu.
Referenced by dwarf_evaluate_loc_desc::dwarf_call(), and symbol_needs_eval_context::dwarf_call().
Definition at line 3703 of file dwarf2loc.c.
References dwarf2_locexpr_baton::data.
Referenced by locexpr_describe_location_piece().
|
static |
Definition at line 2050 of file dwarf2loc.c.
References rw_pieced_value().
Definition at line 1765 of file dwarf2loc.c.
References _, gdbarch::bits_big_endian, bits_to_bytes(), copy_bitwise(), dwarf2_per_cu_objfile(), dwarf_reg_to_regnum_or_error(), DWARF_VALUE_IMPLICIT_POINTER, DWARF_VALUE_LITERAL, DWARF_VALUE_MEMORY, DWARF_VALUE_OPTIMIZED_OUT, DWARF_VALUE_REGISTER, DWARF_VALUE_STACK, frame_find_by_id(), piece_closure::frame_id, gdbarch_bits_big_endian(), gdbarch_byte_order(), get_frame_arch(), get_frame_register_bytes(), get_objfile_arch(), get_type_arch(), internal_error(), dwarf_expr_piece::literal, dwarf_expr_piece::location, mark_value_bits_optimized_out(), mark_value_bits_unavailable(), dwarf_expr_piece::mem, NOT_AVAILABLE_ERROR, offset, dwarf_expr_piece::offset, OPTIMIZED_OUT_ERROR, piece_closure::per_cu, piece_closure::pieces, put_frame_register_bytes(), read_memory(), read_value_memory(), register_size(), dwarf_expr_piece::regno, dwarf_expr_piece::size, throw_error(), TYPE_LENGTH, dwarf_expr_piece::v, dwarf_expr_piece::value, value_bitpos(), value_bitsize(), value_computed_closure(), value_contents(), value_contents_all(), value_contents_raw(), value_enclosing_type(), value_offset(), value_parent(), value_type(), and write_memory_with_notification().
Referenced by read_pieced_value(), and write_pieced_value().
|
static |
Definition at line 730 of file dwarf2loc.c.
References _, and fprintf_filtered().
Referenced by _initialize_dwarf2loc().
Definition at line 914 of file dwarf2loc.c.
References fprintf_unfiltered(), gdb_stdlog, lookup_minimal_symbol_by_pc(), bound_minimal_symbol::minsym, MSYMBOL_PRINT_NAME, paddress(), and call_site::pc.
Referenced by chain_candidate().
|
static |
Definition at line 2906 of file dwarf2loc.c.
References _, error(), and pulongest().
Referenced by dwarf_reg_to_regnum_or_error().
|
static |
Definition at line 2870 of file dwarf2loc.c.
References _, error(), and name.
Referenced by dwarf2_compile_expr_to_ax().
|
static |
Definition at line 1457 of file dwarf2loc.c.
References _, CALL_SITE_PARAMETER_DWARF_REG, CALL_SITE_PARAMETER_FB_OFFSET, dwarf_block_to_dwarf_reg(), dwarf_block_to_fb_offset(), call_site_parameter_u::dwarf_reg, call_site_parameter_u::fb_offset, NO_ENTRY_VALUE_ERROR, throw_error(), and value_of_dwarf_reg_entry().
Referenced by locexpr_read_variable_at_entry(), and loclist_read_variable_at_entry().
|
static |
Definition at line 1405 of file dwarf2loc.c.
References allocate_computed_value(), check_typedef(), dwarf_entry_parameter_to_value(), dwarf_expr_reg_to_entry_parameter(), entry_data_value_funcs, get_prev_frame(), release_value(), set_value_lazy(), TYPE_IS_REFERENCE, TYPE_LENGTH, TYPE_TARGET_TYPE, and value_contents_raw().
Referenced by value_of_dwarf_block_entry().
Definition at line 2056 of file dwarf2loc.c.
References rw_pieced_value().
| const struct symbol_block_ops dwarf2_block_frame_base_locexpr_funcs |
Definition at line 442 of file dwarf2loc.c.
Referenced by _initialize_dwarf2_read().
| const struct symbol_block_ops dwarf2_block_frame_base_loclist_funcs |
Definition at line 499 of file dwarf2loc.c.
Referenced by _initialize_dwarf2_read().
| const struct symbol_computed_ops dwarf2_locexpr_funcs |
Definition at line 4428 of file dwarf2loc.c.
Referenced by _initialize_dwarf2_read().
| const struct symbol_computed_ops dwarf2_loclist_funcs |
Definition at line 4641 of file dwarf2loc.c.
Referenced by _initialize_dwarf2_read().
| int dwarf_always_disassemble |
Definition at line 27045 of file dwarf2read.c.
Referenced by _initialize_dwarf2_read(), and locexpr_describe_location_1().
|
static |
Definition at line 1386 of file dwarf2loc.c.
Referenced by value_of_dwarf_reg_entry().
| unsigned int entry_values_debug = 0 |
Definition at line 725 of file dwarf2loc.c.
Referenced by _initialize_dwarf2loc(), call_site_find_chain(), chain_candidate(), dwarf2_evaluate_loc_desc_full(), and dwarf2_tailcall_sniffer_first().
|
static |
Definition at line 2309 of file dwarf2loc.c.
Referenced by dwarf2_evaluate_loc_desc_full().
1.8.14