GDB (xrefs)
Classes | Macros | Typedefs | Enumerations | Functions | Variables
/tmp/gdb-7.10/gdb/dwarf2read.c File Reference
#include "defs.h"
#include "bfd.h"
#include "elf-bfd.h"
#include "symtab.h"
#include "gdbtypes.h"
#include "objfiles.h"
#include "dwarf2.h"
#include "buildsym.h"
#include "demangle.h"
#include "gdb-demangle.h"
#include "expression.h"
#include "filenames.h"
#include "macrotab.h"
#include "language.h"
#include "complaints.h"
#include "bcache.h"
#include "dwarf2expr.h"
#include "dwarf2loc.h"
#include "cp-support.h"
#include "hashtab.h"
#include "command.h"
#include "gdbcmd.h"
#include "block.h"
#include "addrmap.h"
#include "typeprint.h"
#include "jv-lang.h"
#include "psympriv.h"
#include <sys/stat.h>
#include "completer.h"
#include "vec.h"
#include "c-lang.h"
#include "go-lang.h"
#include "valprint.h"
#include "gdbcore.h"
#include "gdb/gdb-index.h"
#include <ctype.h>
#include "gdb_bfd.h"
#include "f-lang.h"
#include "source.h"
#include "filestuff.h"
#include "build-id.h"
#include <fcntl.h>
#include <sys/types.h>

Go to the source code of this file.

Classes

struct  dwarf2_section_info
 
struct  mapped_index
 
struct  tu_stats
 
struct  dwarf2_per_objfile
 
struct  dwop_section_names
 
struct  comp_unit_head
 
struct  delayed_method_info
 
struct  dwarf2_cu
 
struct  dwarf2_per_cu_data
 
struct  signatured_type
 
struct  stmt_list_hash
 
struct  type_unit_group
 
struct  dwo_sections
 
struct  dwo_unit
 
struct  dwo_file
 
struct  dwp_sections
 
struct  virtual_v1_dwo_sections
 
struct  virtual_v2_dwo_sections
 
struct  dwp_hash_table
 
struct  dwp_file
 
struct  dwz_file
 
struct  die_reader_specs
 
struct  file_entry
 
struct  line_header
 
struct  partial_die_info
 
struct  abbrev_info
 
struct  attr_abbrev
 
struct  abbrev_table
 
struct  attribute
 
struct  die_info
 
struct  dwarf_block
 
struct  nextfield
 
struct  nextfnfield
 
struct  fnfieldlist
 
struct  typedef_field_list
 
struct  field_info
 
struct  dwarf2_queue_item
 
struct  quick_file_names
 
struct  dwarf2_per_cu_quick_data
 
struct  dw2_symtab_iterator
 
struct  process_psymtab_comp_unit_data
 
struct  tu_abbrev_offset
 
struct  create_dwo_cu_data
 
struct  dwarf2_read_addr_index_data
 
struct  lnp_state_machine
 
struct  lnp_reader_state
 
struct  dwarf2_per_cu_offset_and_type
 
struct  strtab_entry
 
struct  symtab_index_entry
 
struct  mapped_symtab
 
struct  psymtab_cu_index_map
 
struct  addrmap_index_data
 
struct  signatured_type_index_data
 

Macros

#define DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE(cu_index, value)
 
#define DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE(cu_index, value)
 
#define DW2_GDB_INDEX_CU_SET_VALUE(cu_index, value)
 
#define IS_TYPE_UNIT_GROUP(per_cu)   ((per_cu)->section == NULL)
 
#define MAX_NR_V2_DWO_SECTIONS
 
#define ABBREV_HASH_SIZE   121
 
#define DW_STRING(attr)    ((attr)->u.str)
 
#define DW_STRING_IS_CANONICAL(attr)   ((attr)->string_is_canonical)
 
#define DW_UNSND(attr)    ((attr)->u.unsnd)
 
#define DW_BLOCK(attr)    ((attr)->u.blk)
 
#define DW_SND(attr)    ((attr)->u.snd)
 
#define DW_ADDR(attr)    ((attr)->u.addr)
 
#define DW_SIGNATURE(attr)   ((attr)->u.signature)
 
#define ATTR_ALLOC_CHUNK   4
 
#define DW_FIELD_ALLOC_CHUNK   4
 
#define MAYBE_SWAP(V)   (V)
 
#define INDEX_SUFFIX   ".gdb-index"
 
#define NO_STMT_LIST_TYPE_UNIT_PSYMTAB   (1 << 31)
 
#define NO_STMT_LIST_TYPE_UNIT_PSYMTAB_SIZE   10
 
#define MAX_NESTED_IMPORTED_DECLARATIONS   100
 
#define MAX_NR_V1_DWO_SECTIONS
 
#define MAX_SEP_LEN   7 /* strlen ("__") + strlen ("_MOD_") */
 

Typedefs

typedef struct symbolsymbolp
 
typedef struct dwarf2_section_info dwarf2_section_info_def
 
typedef uint32_t offset_type
 
typedef struct dwarf2_per_cu_datadwarf2_per_cu_ptr
 
typedef struct delayed_method_info delayed_method_info
 
typedef struct signatured_typesig_type_ptr
 
typedef void( die_reader_func_ftype) (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 

Enumerations

enum  dwp_v2_section_ids { DW_SECT_MIN = 1 }
 

Functions

 DEF_VEC_P (symbolp)
 
 DEF_VEC_O (dwarf2_section_info_def)
 
 DEF_VEC_I (offset_type)
 
 DEF_VEC_P (dwarf2_per_cu_ptr)
 
 DEF_VEC_O (delayed_method_info)
 
 DEF_VEC_P (sig_type_ptr)
 
static void show_dwarf_max_cache_age (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static const char * get_section_name (const struct dwarf2_section_info *)
 
static const char * get_section_file_name (const struct dwarf2_section_info *)
 
static void dwarf2_locate_sections (bfd *, asection *, void *)
 
static void dwarf2_find_base_address (struct die_info *die, struct dwarf2_cu *cu)
 
static struct partial_symtabcreate_partial_symtab (struct dwarf2_per_cu_data *per_cu, const char *name)
 
static void dwarf2_build_psymtabs_hard (struct objfile *)
 
static void scan_partial_symbols (struct partial_die_info *, CORE_ADDR *, CORE_ADDR *, int, struct dwarf2_cu *)
 
static void add_partial_symbol (struct partial_die_info *, struct dwarf2_cu *)
 
static void add_partial_namespace (struct partial_die_info *pdi, CORE_ADDR *lowpc, CORE_ADDR *highpc, int set_addrmap, struct dwarf2_cu *cu)
 
static void add_partial_module (struct partial_die_info *pdi, CORE_ADDR *lowpc, CORE_ADDR *highpc, int set_addrmap, struct dwarf2_cu *cu)
 
static void add_partial_enumeration (struct partial_die_info *enum_pdi, struct dwarf2_cu *cu)
 
static void add_partial_subprogram (struct partial_die_info *pdi, CORE_ADDR *lowpc, CORE_ADDR *highpc, int need_pc, struct dwarf2_cu *cu)
 
static void dwarf2_read_symtab (struct partial_symtab *, struct objfile *)
 
static void psymtab_to_symtab_1 (struct partial_symtab *)
 
static struct abbrev_infoabbrev_table_lookup_abbrev (const struct abbrev_table *, unsigned int)
 
static struct abbrev_tableabbrev_table_read_table (struct dwarf2_section_info *, sect_offset)
 
static void abbrev_table_free (struct abbrev_table *)
 
static void abbrev_table_free_cleanup (void *)
 
static void dwarf2_read_abbrevs (struct dwarf2_cu *, struct dwarf2_section_info *)
 
static void dwarf2_free_abbrev_table (void *)
 
static unsigned int peek_abbrev_code (bfd *, const gdb_byte *)
 
static struct partial_die_infoload_partial_dies (const struct die_reader_specs *, const gdb_byte *, int)
 
static const gdb_byteread_partial_die (const struct die_reader_specs *, struct partial_die_info *, struct abbrev_info *, unsigned int, const gdb_byte *)
 
static struct partial_die_infofind_partial_die (sect_offset, int, struct dwarf2_cu *)
 
static void fixup_partial_die (struct partial_die_info *, struct dwarf2_cu *)
 
static const gdb_byteread_attribute (const struct die_reader_specs *, struct attribute *, struct attr_abbrev *, const gdb_byte *)
 
static unsigned int read_1_byte (bfd *, const gdb_byte *)
 
static int read_1_signed_byte (bfd *, const gdb_byte *)
 
static unsigned int read_2_bytes (bfd *, const gdb_byte *)
 
static unsigned int read_4_bytes (bfd *, const gdb_byte *)
 
static ULONGEST read_8_bytes (bfd *, const gdb_byte *)
 
static CORE_ADDR read_address (bfd *, const gdb_byte *ptr, struct dwarf2_cu *, unsigned int *)
 
static LONGEST read_initial_length (bfd *, const gdb_byte *, unsigned int *)
 
static LONGEST read_checked_initial_length_and_offset (bfd *, const gdb_byte *, const struct comp_unit_head *, unsigned int *, unsigned int *)
 
static LONGEST read_offset (bfd *, const gdb_byte *, const struct comp_unit_head *, unsigned int *)
 
static LONGEST read_offset_1 (bfd *, const gdb_byte *, unsigned int)
 
static sect_offset read_abbrev_offset (struct dwarf2_section_info *, sect_offset)
 
static const gdb_byteread_n_bytes (bfd *, const gdb_byte *, unsigned int)
 
static const char * read_direct_string (bfd *, const gdb_byte *, unsigned int *)
 
static const char * read_indirect_string (bfd *, const gdb_byte *, const struct comp_unit_head *, unsigned int *)
 
static const char * read_indirect_string_from_dwz (struct dwz_file *, LONGEST)
 
static ULONGEST read_unsigned_leb128 (bfd *, const gdb_byte *, unsigned int *)
 
static LONGEST read_signed_leb128 (bfd *, const gdb_byte *, unsigned int *)
 
static CORE_ADDR read_addr_index_from_leb128 (struct dwarf2_cu *, const gdb_byte *, unsigned int *)
 
static const char * read_str_index (const struct die_reader_specs *reader, ULONGEST str_index)
 
static void set_cu_language (unsigned int, struct dwarf2_cu *)
 
static struct attributedwarf2_attr (struct die_info *, unsigned int, struct dwarf2_cu *)
 
static struct attributedwarf2_attr_no_follow (struct die_info *, unsigned int)
 
static int dwarf2_flag_true_p (struct die_info *die, unsigned name, struct dwarf2_cu *cu)
 
static int die_is_declaration (struct die_info *, struct dwarf2_cu *cu)
 
static struct die_infodie_specification (struct die_info *die, struct dwarf2_cu **)
 
static void free_line_header (struct line_header *lh)
 
static struct line_headerdwarf_decode_line_header (unsigned int offset, struct dwarf2_cu *cu)
 
static void dwarf_decode_lines (struct line_header *, const char *, struct dwarf2_cu *, struct partial_symtab *, CORE_ADDR, int decode_mapping)
 
static void dwarf2_start_subfile (const char *, const char *)
 
static struct compunit_symtabdwarf2_start_symtab (struct dwarf2_cu *, const char *, const char *, CORE_ADDR)
 
static struct symbolnew_symbol (struct die_info *, struct type *, struct dwarf2_cu *)
 
static struct symbolnew_symbol_full (struct die_info *, struct type *, struct dwarf2_cu *, struct symbol *)
 
static void dwarf2_const_value (const struct attribute *, struct symbol *, struct dwarf2_cu *)
 
static void dwarf2_const_value_attr (const struct attribute *attr, struct type *type, const char *name, struct obstack *obstack, struct dwarf2_cu *cu, LONGEST *value, const gdb_byte **bytes, struct dwarf2_locexpr_baton **baton)
 
static struct typedie_type (struct die_info *, struct dwarf2_cu *)
 
static int need_gnat_info (struct dwarf2_cu *)
 
static struct typedie_descriptive_type (struct die_info *, struct dwarf2_cu *)
 
static void set_descriptive_type (struct type *, struct die_info *, struct dwarf2_cu *)
 
static struct typedie_containing_type (struct die_info *, struct dwarf2_cu *)
 
static struct typelookup_die_type (struct die_info *, const struct attribute *, struct dwarf2_cu *)
 
static struct typeread_type_die (struct die_info *, struct dwarf2_cu *)
 
static struct typeread_type_die_1 (struct die_info *, struct dwarf2_cu *)
 
static const char * determine_prefix (struct die_info *die, struct dwarf2_cu *)
 
static char * typename_concat (struct obstack *obs, const char *prefix, const char *suffix, int physname, struct dwarf2_cu *cu)
 
static void read_file_scope (struct die_info *, struct dwarf2_cu *)
 
static void read_type_unit_scope (struct die_info *, struct dwarf2_cu *)
 
static void read_func_scope (struct die_info *, struct dwarf2_cu *)
 
static void read_lexical_block_scope (struct die_info *, struct dwarf2_cu *)
 
static void read_call_site_scope (struct die_info *die, struct dwarf2_cu *cu)
 
static int dwarf2_ranges_read (unsigned, CORE_ADDR *, CORE_ADDR *, struct dwarf2_cu *, struct partial_symtab *)
 
static int dwarf2_get_pc_bounds (struct die_info *, CORE_ADDR *, CORE_ADDR *, struct dwarf2_cu *, struct partial_symtab *)
 
static void get_scope_pc_bounds (struct die_info *, CORE_ADDR *, CORE_ADDR *, struct dwarf2_cu *)
 
static void dwarf2_record_block_ranges (struct die_info *, struct block *, CORE_ADDR, struct dwarf2_cu *)
 
static void dwarf2_add_field (struct field_info *, struct die_info *, struct dwarf2_cu *)
 
static void dwarf2_attach_fields_to_type (struct field_info *, struct type *, struct dwarf2_cu *)
 
static void dwarf2_add_member_fn (struct field_info *, struct die_info *, struct type *, struct dwarf2_cu *)
 
static void dwarf2_attach_fn_fields_to_type (struct field_info *, struct type *, struct dwarf2_cu *)
 
static void process_structure_scope (struct die_info *, struct dwarf2_cu *)
 
static void read_common_block (struct die_info *, struct dwarf2_cu *)
 
static void read_namespace (struct die_info *die, struct dwarf2_cu *)
 
static void read_module (struct die_info *die, struct dwarf2_cu *cu)
 
static void read_import_statement (struct die_info *die, struct dwarf2_cu *)
 
static int read_namespace_alias (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_module_type (struct die_info *die, struct dwarf2_cu *cu)
 
static const char * namespace_name (struct die_info *die, int *is_anonymous, struct dwarf2_cu *)
 
static void process_enumeration_scope (struct die_info *, struct dwarf2_cu *)
 
static CORE_ADDR decode_locdesc (struct dwarf_block *, struct dwarf2_cu *)
 
static enum dwarf_array_dim_ordering read_array_order (struct die_info *, struct dwarf2_cu *)
 
static struct die_inforead_die_and_siblings_1 (const struct die_reader_specs *, const gdb_byte *, const gdb_byte **, struct die_info *)
 
static struct die_inforead_die_and_siblings (const struct die_reader_specs *, const gdb_byte *info_ptr, const gdb_byte **new_info_ptr, struct die_info *parent)
 
static const gdb_byteread_full_die_1 (const struct die_reader_specs *, struct die_info **, const gdb_byte *, int *, int)
 
static const gdb_byteread_full_die (const struct die_reader_specs *, struct die_info **, const gdb_byte *, int *)
 
static void process_die (struct die_info *, struct dwarf2_cu *)
 
static const char * dwarf2_canonicalize_name (const char *, struct dwarf2_cu *, struct obstack *)
 
static const char * dwarf2_name (struct die_info *die, struct dwarf2_cu *)
 
static const char * dwarf2_full_name (const char *name, struct die_info *die, struct dwarf2_cu *cu)
 
static const char * dwarf2_physname (const char *name, struct die_info *die, struct dwarf2_cu *cu)
 
static struct die_infodwarf2_extension (struct die_info *die, struct dwarf2_cu **)
 
static const char * dwarf_tag_name (unsigned int)
 
static const char * dwarf_attr_name (unsigned int)
 
static const char * dwarf_form_name (unsigned int)
 
static char * dwarf_bool_name (unsigned int)
 
static const char * dwarf_type_encoding_name (unsigned int)
 
static struct die_infosibling_die (struct die_info *)
 
static void dump_die_shallow (struct ui_file *, int indent, struct die_info *)
 
static void dump_die_for_error (struct die_info *)
 
static void dump_die_1 (struct ui_file *, int level, int max_level, struct die_info *)
 
void dump_die (struct die_info *, int max_level)
 
static void store_in_ref_table (struct die_info *, struct dwarf2_cu *)
 
static sect_offset dwarf2_get_ref_die_offset (const struct attribute *)
 
static LONGEST dwarf2_get_attr_constant_value (const struct attribute *, int)
 
static struct die_infofollow_die_ref_or_sig (struct die_info *, const struct attribute *, struct dwarf2_cu **)
 
static struct die_infofollow_die_ref (struct die_info *, const struct attribute *, struct dwarf2_cu **)
 
static struct die_infofollow_die_sig (struct die_info *, const struct attribute *, struct dwarf2_cu **)
 
static struct typeget_signatured_type (struct die_info *, ULONGEST, struct dwarf2_cu *)
 
static struct typeget_DW_AT_signature_type (struct die_info *, const struct attribute *, struct dwarf2_cu *)
 
static void load_full_type_unit (struct dwarf2_per_cu_data *per_cu)
 
static void read_signatured_type (struct signatured_type *)
 
static struct dwarf_blockdwarf_alloc_block (struct dwarf2_cu *)
 
static struct die_infodwarf_alloc_die (struct dwarf2_cu *, int)
 
static void dwarf_decode_macros (struct dwarf2_cu *, unsigned int, int)
 
static int attr_form_is_block (const struct attribute *)
 
static int attr_form_is_section_offset (const struct attribute *)
 
static int attr_form_is_constant (const struct attribute *)
 
static int attr_form_is_ref (const struct attribute *)
 
static void fill_in_loclist_baton (struct dwarf2_cu *cu, struct dwarf2_loclist_baton *baton, const struct attribute *attr)
 
static void dwarf2_symbol_mark_computed (const struct attribute *attr, struct symbol *sym, struct dwarf2_cu *cu, int is_block)
 
static const gdb_byteskip_one_die (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct abbrev_info *abbrev)
 
static void free_stack_comp_unit (void *)
 
static hashval_t partial_die_hash (const void *item)
 
static int partial_die_eq (const void *item_lhs, const void *item_rhs)
 
static struct dwarf2_per_cu_datadwarf2_find_containing_comp_unit (sect_offset offset, unsigned int offset_in_dwz, struct objfile *objfile)
 
static void init_one_comp_unit (struct dwarf2_cu *cu, struct dwarf2_per_cu_data *per_cu)
 
static void prepare_one_comp_unit (struct dwarf2_cu *cu, struct die_info *comp_unit_die, enum language pretend_language)
 
static void free_heap_comp_unit (void *)
 
static void free_cached_comp_units (void *)
 
static void age_cached_comp_units (void)
 
static void free_one_cached_comp_unit (struct dwarf2_per_cu_data *)
 
static struct typeset_die_type (struct die_info *, struct type *, struct dwarf2_cu *)
 
static void create_all_comp_units (struct objfile *)
 
static int create_all_type_units (struct objfile *)
 
static void load_full_comp_unit (struct dwarf2_per_cu_data *, enum language)
 
static void process_full_comp_unit (struct dwarf2_per_cu_data *, enum language)
 
static void process_full_type_unit (struct dwarf2_per_cu_data *, enum language)
 
static void dwarf2_add_dependence (struct dwarf2_cu *, struct dwarf2_per_cu_data *)
 
static void dwarf2_mark (struct dwarf2_cu *)
 
static void dwarf2_clear_marks (struct dwarf2_per_cu_data *)
 
static struct typeget_die_type_at_offset (sect_offset, struct dwarf2_per_cu_data *)
 
static struct typeget_die_type (struct die_info *die, struct dwarf2_cu *cu)
 
static void dwarf2_release_queue (void *dummy)
 
static void queue_comp_unit (struct dwarf2_per_cu_data *per_cu, enum language pretend_language)
 
static void process_queue (void)
 
static void find_file_and_directory (struct die_info *die, struct dwarf2_cu *cu, const char **name, const char **comp_dir)
 
static char * file_full_name (int file, struct line_header *lh, const char *comp_dir)
 
static const gdb_byteread_and_check_comp_unit_head (struct comp_unit_head *header, struct dwarf2_section_info *section, struct dwarf2_section_info *abbrev_section, const gdb_byte *info_ptr, int is_debug_types_section)
 
static void init_cutu_and_read_dies (struct dwarf2_per_cu_data *this_cu, struct abbrev_table *abbrev_table, int use_existing_cu, int keep, die_reader_func_ftype *die_reader_func, void *data)
 
static void init_cutu_and_read_dies_simple (struct dwarf2_per_cu_data *this_cu, die_reader_func_ftype *die_reader_func, void *data)
 
static htab_t allocate_signatured_type_table (struct objfile *objfile)
 
static htab_t allocate_dwo_unit_table (struct objfile *objfile)
 
static struct dwo_unitlookup_dwo_unit_in_dwp (struct dwp_file *dwp_file, const char *comp_dir, ULONGEST signature, int is_debug_types)
 
static struct dwp_fileget_dwp_file (void)
 
static struct dwo_unitlookup_dwo_comp_unit (struct dwarf2_per_cu_data *, const char *, const char *, ULONGEST)
 
static struct dwo_unitlookup_dwo_type_unit (struct signatured_type *, const char *, const char *)
 
static void queue_and_load_all_dwo_tus (struct dwarf2_per_cu_data *)
 
static void free_dwo_file_cleanup (void *)
 
static void process_cu_includes (void)
 
static void check_producer (struct dwarf2_cu *cu)
 
static void free_line_header_voidp (void *arg)
 
static void dwarf2_statement_list_fits_in_line_number_section_complaint (void)
 
static void dwarf2_debug_line_missing_file_complaint (void)
 
static void dwarf2_debug_line_missing_end_sequence_complaint (void)
 
static void dwarf2_complex_location_expr_complaint (void)
 
static void dwarf2_const_value_length_mismatch_complaint (const char *arg1, int arg2, int arg3)
 
static void dwarf2_section_buffer_overflow_complaint (struct dwarf2_section_info *section)
 
static void dwarf2_macro_malformed_definition_complaint (const char *arg1)
 
static void dwarf2_invalid_attrib_class_complaint (const char *arg1, const char *arg2)
 
static hashval_t line_header_hash (const struct line_header *ofs)
 
static hashval_t line_header_hash_voidp (const void *item)
 
static int line_header_eq_voidp (const void *item_lhs, const void *item_rhs)
 
static CORE_ADDR attr_value_as_address (struct attribute *attr)
 
int dwarf2_has_info (struct objfile *objfile, const struct dwarf2_debug_sections *names)
 
static struct dwarf2_section_infoget_containing_section (const struct dwarf2_section_info *section)
 
static struct bfd * get_section_bfd_owner (const struct dwarf2_section_info *section)
 
static asection * get_section_bfd_section (const struct dwarf2_section_info *section)
 
static int get_section_id (const struct dwarf2_section_info *section)
 
static int get_section_flags (const struct dwarf2_section_info *section)
 
static int section_is_p (const char *section_name, const struct dwarf2_section_names *names)
 
static int dwarf2_section_empty_p (const struct dwarf2_section_info *section)
 
static void dwarf2_read_section (struct objfile *objfile, struct dwarf2_section_info *info)
 
static bfd_size_type dwarf2_section_size (struct objfile *objfile, struct dwarf2_section_info *info)
 
void dwarf2_get_section_info (struct objfile *objfile, enum dwarf2_section_enum sect, asection **sectp, const gdb_byte **bufp, bfd_size_type *sizep)
 
static void locate_dwz_sections (bfd *abfd, asection *sectp, void *arg)
 
static struct dwz_filedwarf2_get_dwz_file (void)
 
static hashval_t hash_stmt_list_entry (const struct stmt_list_hash *stmt_list_hash)
 
static int eq_stmt_list_entry (const struct stmt_list_hash *lhs, const struct stmt_list_hash *rhs)
 
static hashval_t hash_file_name_entry (const void *e)
 
static int eq_file_name_entry (const void *a, const void *b)
 
static void delete_file_name_entry (void *e)
 
static htab_t create_quick_file_names_table (unsigned int nr_initial_entries)
 
static void load_cu (struct dwarf2_per_cu_data *per_cu)
 
static void dw2_do_instantiate_symtab (struct dwarf2_per_cu_data *per_cu)
 
static struct compunit_symtabdw2_instantiate_symtab (struct dwarf2_per_cu_data *per_cu)
 
static struct dwarf2_per_cu_datadw2_get_cutu (int index)
 
static struct dwarf2_per_cu_datadw2_get_cu (int index)
 
static void create_cus_from_index_list (struct objfile *objfile, const gdb_byte *cu_list, offset_type n_elements, struct dwarf2_section_info *section, int is_dwz, int base_offset)
 
static void create_cus_from_index (struct objfile *objfile, const gdb_byte *cu_list, offset_type cu_list_elements, const gdb_byte *dwz_list, offset_type dwz_elements)
 
static void create_signatured_type_table_from_index (struct objfile *objfile, struct dwarf2_section_info *section, const gdb_byte *bytes, offset_type elements)
 
static void create_addrmap_from_index (struct objfile *objfile, struct mapped_index *index)
 
static hashval_t mapped_index_string_hash (int index_version, const void *p)
 
static int find_slot_in_mapped_hash (struct mapped_index *index, const char *name, offset_type **vec_out)
 
static int read_index_from_section (struct objfile *objfile, const char *filename, int deprecated_ok, struct dwarf2_section_info *section, struct mapped_index *map, const gdb_byte **cu_list, offset_type *cu_list_elements, const gdb_byte **types_list, offset_type *types_list_elements)
 
static int dwarf2_read_index (struct objfile *objfile)
 
static void dw2_setup (struct objfile *objfile)
 
static void dw2_get_file_names_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 
static struct quick_file_namesdw2_get_file_names (struct dwarf2_per_cu_data *this_cu)
 
static const char * dw2_get_real_path (struct objfile *objfile, struct quick_file_names *qfn, int index)
 
static struct symtabdw2_find_last_source_symtab (struct objfile *objfile)
 
static int dw2_free_cached_file_names (void **slot, void *info)
 
static void dw2_forget_cached_source_info (struct objfile *objfile)
 
static int dw2_map_expand_apply (struct objfile *objfile, struct dwarf2_per_cu_data *per_cu, const char *name, const char *real_path, int(*callback)(struct symtab *, void *), void *data)
 
static int dw2_map_symtabs_matching_filename (struct objfile *objfile, const char *name, const char *real_path, int(*callback)(struct symtab *, void *), void *data)
 
static void dw2_symtab_iter_init (struct dw2_symtab_iterator *iter, struct mapped_index *index, int want_specific_block, int block_index, domain_enum domain, const char *name)
 
static struct dwarf2_per_cu_datadw2_symtab_iter_next (struct dw2_symtab_iterator *iter)
 
static struct compunit_symtabdw2_lookup_symbol (struct objfile *objfile, int block_index, const char *name, domain_enum domain)
 
static void dw2_print_stats (struct objfile *objfile)
 
static void dw2_dump (struct objfile *objfile)
 
static void dw2_relocate (struct objfile *objfile, const struct section_offsets *new_offsets, const struct section_offsets *delta)
 
static void dw2_expand_symtabs_for_function (struct objfile *objfile, const char *func_name)
 
static void dw2_expand_all_symtabs (struct objfile *objfile)
 
static void dw2_expand_symtabs_with_fullname (struct objfile *objfile, const char *fullname)
 
static void dw2_map_matching_symbols (struct objfile *objfile, const char *name, domain_enum domain, int global, int(*callback)(struct block *, struct symbol *, void *), void *data, symbol_compare_ftype *match, symbol_compare_ftype *ordered_compare)
 
static void dw2_expand_symtabs_matching (struct objfile *objfile, expand_symtabs_file_matcher_ftype *file_matcher, expand_symtabs_symbol_matcher_ftype *symbol_matcher, expand_symtabs_exp_notify_ftype *expansion_notify, enum search_domain kind, void *data)
 
static struct compunit_symtabrecursively_find_pc_sect_compunit_symtab (struct compunit_symtab *cust, CORE_ADDR pc)
 
static struct compunit_symtabdw2_find_pc_sect_compunit_symtab (struct objfile *objfile, struct bound_minimal_symbol msymbol, CORE_ADDR pc, struct obj_section *section, int warn_if_readin)
 
static void dw2_map_symbol_filenames (struct objfile *objfile, symbol_filename_ftype *fun, void *data, int need_fullname)
 
static int dw2_has_symbols (struct objfile *objfile)
 
int dwarf2_initialize_objfile (struct objfile *objfile)
 
void dwarf2_build_psymtabs (struct objfile *objfile)
 
static unsigned int get_cu_length (const struct comp_unit_head *header)
 
static int offset_in_cu_p (const struct comp_unit_head *cu_header, sect_offset offset)
 
static const gdb_byteread_comp_unit_head (struct comp_unit_head *cu_header, const gdb_byte *info_ptr, bfd *abfd)
 
static struct dwarf2_section_infoget_abbrev_section_for_cu (struct dwarf2_per_cu_data *this_cu)
 
static void error_check_comp_unit_head (struct comp_unit_head *header, struct dwarf2_section_info *section, struct dwarf2_section_info *abbrev_section)
 
static const gdb_byteread_and_check_type_unit_head (struct comp_unit_head *header, struct dwarf2_section_info *section, struct dwarf2_section_info *abbrev_section, const gdb_byte *info_ptr, ULONGEST *signature, cu_offset *type_offset_in_tu)
 
static void dwarf2_create_include_psymtab (const char *name, struct partial_symtab *pst, struct objfile *objfile)
 
static void dwarf2_build_include_psymtabs (struct dwarf2_cu *cu, struct die_info *die, struct partial_symtab *pst)
 
static hashval_t hash_signatured_type (const void *item)
 
static int eq_signatured_type (const void *item_lhs, const void *item_rhs)
 
static int add_signatured_type_cu_to_table (void **slot, void *datum)
 
static htab_t create_debug_types_hash_table (struct dwo_file *dwo_file, VEC(dwarf2_section_info_def)*types)
 
static struct signatured_typeadd_type_unit (ULONGEST sig, void **slot)
 
static void fill_in_sig_entry_from_dwo_entry (struct objfile *objfile, struct signatured_type *sig_entry, struct dwo_unit *dwo_entry)
 
static struct signatured_typelookup_dwo_signatured_type (struct dwarf2_cu *cu, ULONGEST sig)
 
static struct signatured_typelookup_dwp_signatured_type (struct dwarf2_cu *cu, ULONGEST sig)
 
static struct signatured_typelookup_signatured_type (struct dwarf2_cu *cu, ULONGEST sig)
 
static void init_cu_die_reader (struct die_reader_specs *reader, struct dwarf2_cu *cu, struct dwarf2_section_info *section, struct dwo_file *dwo_file)
 
static int read_cutu_die_from_dwo (struct dwarf2_per_cu_data *this_cu, struct dwo_unit *dwo_unit, int abbrev_table_provided, struct die_info *stub_comp_unit_die, const char *stub_comp_dir, struct die_reader_specs *result_reader, const gdb_byte **result_info_ptr, struct die_info **result_comp_unit_die, int *result_has_children)
 
static struct dwo_unitlookup_dwo_unit (struct dwarf2_per_cu_data *this_cu, struct die_info *comp_unit_die)
 
static void init_tu_and_read_dwo_dies (struct dwarf2_per_cu_data *this_cu, int use_existing_cu, int keep, die_reader_func_ftype *die_reader_func, void *data)
 
static void init_cutu_and_read_dies_no_follow (struct dwarf2_per_cu_data *this_cu, struct dwo_file *dwo_file, die_reader_func_ftype *die_reader_func, void *data)
 
static hashval_t hash_type_unit_group (const void *item)
 
static int eq_type_unit_group (const void *item_lhs, const void *item_rhs)
 
static htab_t allocate_type_unit_groups_table (void)
 
static struct type_unit_groupcreate_type_unit_group (struct dwarf2_cu *cu, sect_offset line_offset_struct)
 
static struct type_unit_groupget_type_unit_group (struct dwarf2_cu *cu, const struct attribute *stmt_list)
 
static void process_psymtab_comp_unit_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 
static void process_psymtab_comp_unit (struct dwarf2_per_cu_data *this_cu, int want_partial_unit, enum language pretend_language)
 
static void build_type_psymtabs_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *type_unit_die, int has_children, void *data)
 
static int sort_tu_by_abbrev_offset (const void *ap, const void *bp)
 
static void build_type_psymtabs_1 (void)
 
static void print_tu_stats (void)
 
static int build_type_psymtab_dependencies (void **slot, void *info)
 
static void build_type_psymtabs (struct objfile *objfile)
 
static int process_skeletonless_type_unit (void **slot, void *info)
 
static int process_dwo_file_for_skeletonless_type_units (void **slot, void *info)
 
static void process_skeletonless_type_units (struct objfile *objfile)
 
static void psymtabs_addrmap_cleanup (void *o)
 
static void set_partial_user (struct objfile *objfile)
 
static void load_partial_comp_unit_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 
static void load_partial_comp_unit (struct dwarf2_per_cu_data *this_cu)
 
static void read_comp_units_from_section (struct objfile *objfile, struct dwarf2_section_info *section, unsigned int is_dwz, int *n_allocated, int *n_comp_units, struct dwarf2_per_cu_data ***all_comp_units)
 
static const char * partial_die_parent_scope (struct partial_die_info *pdi, struct dwarf2_cu *cu)
 
static char * partial_die_full_name (struct partial_die_info *pdi, struct dwarf2_cu *cu)
 
static struct abbrev_infopeek_die_abbrev (const gdb_byte *info_ptr, unsigned int *bytes_read, struct dwarf2_cu *cu)
 
static const gdb_byteskip_children (const struct die_reader_specs *reader, const gdb_byte *info_ptr)
 
static const gdb_bytelocate_pdi_sibling (const struct die_reader_specs *reader, struct partial_die_info *orig_pdi, const gdb_byte *info_ptr)
 
static int maybe_queue_comp_unit (struct dwarf2_cu *dependent_cu, struct dwarf2_per_cu_data *per_cu, enum language pretend_language)
 
static hashval_t die_hash (const void *item)
 
static int die_eq (const void *item_lhs, const void *item_rhs)
 
static void load_full_comp_unit_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 
static void add_to_method_list (struct type *type, int fnfield_index, int index, const char *name, struct die_info *die, struct dwarf2_cu *cu)
 
static void free_delayed_list (void *ptr)
 
static void compute_delayed_physnames (struct dwarf2_cu *cu)
 
static void fixup_go_packaging (struct dwarf2_cu *cu)
 
static struct compunit_symtabget_compunit_symtab (struct dwarf2_per_cu_data *per_cu)
 
static void recursively_compute_inclusions (VEC(compunit_symtab_ptr)**result, htab_t all_children, htab_t all_type_symtabs, struct dwarf2_per_cu_data *per_cu, struct compunit_symtab *immediate_parent)
 
static void compute_compunit_symtab_includes (struct dwarf2_per_cu_data *per_cu)
 
static void process_imported_unit_die (struct die_info *die, struct dwarf2_cu *cu)
 
static void reset_die_in_process (void *arg)
 
static int die_needs_namespace (struct die_info *die, struct dwarf2_cu *cu)
 
static void do_ui_file_peek_last (void *object, const char *buffer, long length)
 
static const char * dwarf2_compute_name (const char *name, struct die_info *die, struct dwarf2_cu *cu, int physname)
 
static void free_cu_line_header (void *arg)
 
static int producer_is_gcc_lt_4_3 (struct dwarf2_cu *cu)
 
static void handle_DW_AT_stmt_list (struct die_info *die, struct dwarf2_cu *cu, const char *comp_dir, CORE_ADDR lowpc)
 
static void setup_type_unit_groups (struct die_info *die, struct dwarf2_cu *cu)
 
static hashval_t hash_dwo_file (const void *item)
 
static int eq_dwo_file (const void *item_lhs, const void *item_rhs)
 
static htab_t allocate_dwo_file_hash_table (void)
 
static void ** lookup_dwo_file_slot (const char *dwo_name, const char *comp_dir)
 
static hashval_t hash_dwo_unit (const void *item)
 
static int eq_dwo_unit (const void *item_lhs, const void *item_rhs)
 
static void create_dwo_cu_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *datap)
 
static struct dwo_unitcreate_dwo_cu (struct dwo_file *dwo_file)
 
static struct dwp_hash_tablecreate_dwp_hash_table (struct dwp_file *dwp_file, int is_debug_types)
 
static int locate_v1_virtual_dwo_sections (asection *sectp, struct virtual_v1_dwo_sections *sections)
 
static struct dwo_unitcreate_dwo_unit_in_dwp_v1 (struct dwp_file *dwp_file, uint32_t unit_index, const char *comp_dir, ULONGEST signature, int is_debug_types)
 
static struct dwarf2_section_info create_dwp_v2_section (struct dwarf2_section_info *section, bfd_size_type offset, bfd_size_type size)
 
static struct dwo_unitcreate_dwo_unit_in_dwp_v2 (struct dwp_file *dwp_file, uint32_t unit_index, const char *comp_dir, ULONGEST signature, int is_debug_types)
 
static bfd * try_open_dwop_file (const char *file_name, int is_dwp, int search_cwd)
 
static bfd * open_dwo_file (const char *file_name, const char *comp_dir)
 
static void dwarf2_locate_dwo_sections (bfd *abfd, asection *sectp, void *dwo_sections_ptr)
 
static struct dwo_fileopen_and_init_dwo_file (struct dwarf2_per_cu_data *per_cu, const char *dwo_name, const char *comp_dir)
 
static void dwarf2_locate_common_dwp_sections (bfd *abfd, asection *sectp, void *dwp_file_ptr)
 
static void dwarf2_locate_v2_dwp_sections (bfd *abfd, asection *sectp, void *dwp_file_ptr)
 
static hashval_t hash_dwp_loaded_cutus (const void *item)
 
static int eq_dwp_loaded_cutus (const void *a, const void *b)
 
static htab_t allocate_dwp_loaded_cutus_table (struct objfile *objfile)
 
static bfd * open_dwp_file (const char *file_name)
 
static struct dwp_fileopen_and_init_dwp_file (void)
 
static struct dwo_unitlookup_dwo_cutu (struct dwarf2_per_cu_data *this_unit, const char *dwo_name, const char *comp_dir, ULONGEST signature, int is_debug_types)
 
static int queue_and_load_dwo_tu (void **slot, void *info)
 
static void free_dwo_file (struct dwo_file *dwo_file, struct objfile *objfile)
 
static int free_dwo_file_from_slot (void **slot, void *info)
 
static void free_dwo_files (htab_t dwo_files, struct objfile *objfile)
 
static int unsigned_int_compar (const void *ap, const void *bp)
 
static void inherit_abstract_dies (struct die_info *die, struct dwarf2_cu *cu)
 
static void dwarf2_get_subprogram_pc_bounds (struct die_info *die, CORE_ADDR *lowpc, CORE_ADDR *highpc, struct dwarf2_cu *cu)
 
static int producer_is_gxx_lt_4_6 (struct dwarf2_cu *cu)
 
static enum dwarf_access_attribute dwarf2_default_access_attribute (struct die_info *die, struct dwarf2_cu *cu)
 
static int handle_data_member_location (struct die_info *die, struct dwarf2_cu *cu, LONGEST *offset)
 
static void dwarf2_add_typedef (struct field_info *fip, struct die_info *die, struct dwarf2_cu *cu)
 
static int dwarf2_is_constructor (struct die_info *die, struct dwarf2_cu *cu)
 
static int is_vtable_name (const char *name, struct dwarf2_cu *cu)
 
static void quirk_gcc_member_function_pointer (struct type *type, struct objfile *objfile)
 
static int producer_is_icc (struct dwarf2_cu *cu)
 
static struct typeread_structure_type (struct die_info *die, struct dwarf2_cu *cu)
 
static void update_enumeration_type_from_children (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
 
static struct typeread_enumeration_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_array_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_set_type (struct die_info *die, struct dwarf2_cu *cu)
 
static void mark_common_block_symbol_computed (struct symbol *sym, struct die_info *common_die, struct attribute *common_loc, struct attribute *member_loc, struct dwarf2_cu *cu)
 
static struct typeread_namespace_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_pointer_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_ptr_to_member_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_reference_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeadd_array_cv_type (struct die_info *die, struct dwarf2_cu *cu, struct type *base_type, int cnst, int voltl)
 
static struct typeread_tag_const_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_volatile_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_restrict_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_atomic_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
 
static int prototyped_function_p (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_subroutine_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_typedef (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_base_type (struct die_info *die, struct dwarf2_cu *cu)
 
static int attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die, struct dwarf2_cu *cu, struct dynamic_prop *prop)
 
static struct typeread_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct typeread_unspecified_type (struct die_info *die, struct dwarf2_cu *cu)
 
static struct die_inforead_die_and_children (const struct die_reader_specs *reader, const gdb_byte *info_ptr, const gdb_byte **new_info_ptr, struct die_info *parent)
 
static struct abbrev_infoabbrev_table_alloc_abbrev (struct abbrev_table *abbrev_table)
 
static void abbrev_table_add_abbrev (struct abbrev_table *abbrev_table, unsigned int abbrev_number, struct abbrev_info *abbrev)
 
static int is_type_tag_for_partial (int tag)
 
static struct partial_die_infofind_partial_die_in_comp_unit (sect_offset offset, struct dwarf2_cu *cu)
 
static void guess_partial_die_structure_name (struct partial_die_info *struct_pdi, struct dwarf2_cu *cu)
 
static const gdb_byteread_attribute_value (const struct die_reader_specs *reader, struct attribute *attr, unsigned form, const gdb_byte *info_ptr)
 
static int read_2_signed_bytes (bfd *abfd, const gdb_byte *buf)
 
static int read_4_signed_bytes (bfd *abfd, const gdb_byte *buf)
 
static const char * read_indirect_string_at_offset (bfd *abfd, LONGEST str_offset)
 
static CORE_ADDR read_addr_index_1 (unsigned int addr_index, ULONGEST addr_base, int addr_size)
 
static CORE_ADDR read_addr_index (struct dwarf2_cu *cu, unsigned int addr_index)
 
static void dwarf2_read_addr_index_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 
CORE_ADDR dwarf2_read_addr_index (struct dwarf2_per_cu_data *per_cu, unsigned int addr_index)
 
static int leb128_size (const gdb_byte *buf)
 
static void add_include_dir (struct line_header *lh, const char *include_dir)
 
static void add_file_name (struct line_header *lh, const char *name, unsigned int dir_index, unsigned int mod_time, unsigned int length)
 
static struct dwarf2_section_infoget_debug_line_section (struct dwarf2_cu *cu)
 
static const char * psymtab_include_file_name (const struct line_header *lh, int file_index, const struct partial_symtab *pst, const char *comp_dir)
 
static void noop_record_line (struct subfile *subfile, int line, CORE_ADDR pc)
 
static int dwarf_record_line_p (unsigned int line, unsigned int last_line, int line_has_non_zero_discriminator, struct subfile *last_subfile)
 
static void dwarf_record_line_1 (struct gdbarch *gdbarch, struct subfile *subfile, unsigned int line, CORE_ADDR address, record_line_ftype p_record_line)
 
static void dwarf_finish_line (struct gdbarch *gdbarch, struct subfile *subfile, CORE_ADDR address, record_line_ftype p_record_line)
 
static void dwarf_record_line (lnp_reader_state *reader, lnp_state_machine *state, int end_sequence)
 
static void init_lnp_state_machine (lnp_state_machine *state, const lnp_reader_state *reader)
 
static void check_line_address (struct dwarf2_cu *cu, lnp_state_machine *state, const gdb_byte *line_ptr, CORE_ADDR lowpc, CORE_ADDR address)
 
static void dwarf_decode_lines_1 (struct line_header *lh, struct dwarf2_cu *cu, const int decode_for_pst_p, CORE_ADDR lowpc)
 
static void var_decode_location (struct attribute *attr, struct symbol *sym, struct dwarf2_cu *cu)
 
static gdb_bytedwarf2_const_value_data (const struct attribute *attr, struct obstack *obstack, struct dwarf2_cu *cu, LONGEST *value, int bits)
 
static struct typebuild_error_marker_type (struct dwarf2_cu *cu, struct die_info *die)
 
static char * guess_full_die_structure_name (struct die_info *die, struct dwarf2_cu *cu)
 
static char * anonymous_struct_prefix (struct die_info *die, struct dwarf2_cu *cu)
 
static struct die_infofollow_die_offset (sect_offset offset, int offset_in_dwz, struct dwarf2_cu **ref_cu)
 
struct dwarf2_locexpr_baton dwarf2_fetch_die_loc_sect_off (sect_offset offset, struct dwarf2_per_cu_data *per_cu, CORE_ADDR(*get_frame_pc)(void *baton), void *baton)
 
struct dwarf2_locexpr_baton dwarf2_fetch_die_loc_cu_off (cu_offset offset_in_cu, struct dwarf2_per_cu_data *per_cu, CORE_ADDR(*get_frame_pc)(void *baton), void *baton)
 
static const gdb_bytewrite_constant_as_bytes (struct obstack *obstack, enum bfd_endian byte_order, struct type *type, ULONGEST value, LONGEST *len)
 
const gdb_bytedwarf2_fetch_constant_bytes (sect_offset offset, struct dwarf2_per_cu_data *per_cu, struct obstack *obstack, LONGEST *len)
 
struct typedwarf2_get_die_type (cu_offset die_offset, struct dwarf2_per_cu_data *per_cu)
 
static struct die_infofollow_die_sig_1 (struct die_info *src_die, struct signatured_type *sig_type, struct dwarf2_cu **ref_cu)
 
static void read_signatured_type_reader (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)
 
static char * file_file_name (int file, struct line_header *lh)
 
static struct macro_source_filemacro_start_file (int file, int line, struct macro_source_file *current_file, struct line_header *lh)
 
static char * copy_string (const char *buf, int len)
 
static const char * consume_improper_spaces (const char *p, const char *body)
 
static void parse_macro_definition (struct macro_source_file *file, int line, const char *body)
 
static const gdb_byteskip_form_bytes (bfd *abfd, const gdb_byte *bytes, const gdb_byte *buffer_end, enum dwarf_form form, unsigned int offset_size, struct dwarf2_section_info *section)
 
static const gdb_byteskip_unknown_opcode (unsigned int opcode, const gdb_byte **opcode_definitions, const gdb_byte *mac_ptr, const gdb_byte *mac_end, bfd *abfd, unsigned int offset_size, struct dwarf2_section_info *section)
 
static const gdb_bytedwarf_parse_macro_header (const gdb_byte **opcode_definitions, bfd *abfd, const gdb_byte *mac_ptr, unsigned int *offset_size, int section_is_gnu)
 
static void dwarf_decode_macro_bytes (bfd *abfd, const gdb_byte *mac_ptr, const gdb_byte *mac_end, struct macro_source_file *current_file, struct line_header *lh, struct dwarf2_section_info *section, int section_is_gnu, int section_is_dwz, unsigned int offset_size, htab_t include_hash)
 
static struct dwarf2_section_infocu_debug_loc_section (struct dwarf2_cu *cu)
 
struct objfiledwarf2_per_cu_objfile (struct dwarf2_per_cu_data *per_cu)
 
static const struct comp_unit_headper_cu_header_read_in (struct comp_unit_head *cu_headerp, struct dwarf2_per_cu_data *per_cu)
 
int dwarf2_per_cu_addr_size (struct dwarf2_per_cu_data *per_cu)
 
int dwarf2_per_cu_offset_size (struct dwarf2_per_cu_data *per_cu)
 
int dwarf2_per_cu_ref_addr_size (struct dwarf2_per_cu_data *per_cu)
 
CORE_ADDR dwarf2_per_cu_text_offset (struct dwarf2_per_cu_data *per_cu)
 
void dwarf2_free_objfile (struct objfile *objfile)
 
static hashval_t per_cu_offset_and_type_hash (const void *item)
 
static int per_cu_offset_and_type_eq (const void *item_lhs, const void *item_rhs)
 
static int dwarf2_mark_helper (void **slot, void *data)
 
static void set_dwarf_cmd (char *args, int from_tty)
 
static void show_dwarf_cmd (char *args, int from_tty)
 
static void dwarf2_per_objfile_free (struct objfile *objfile, void *d)
 
static hashval_t hash_strtab_entry (const void *e)
 
static int eq_strtab_entry (const void *a, const void *b)
 
static htab_t create_strtab (void)
 
static offset_type add_string (htab_t table, struct obstack *cpool, const char *str)
 
static hashval_t hash_symtab_entry (const void *e)
 
static int eq_symtab_entry (const void *a, const void *b)
 
static void delete_symtab_entry (void *p)
 
static htab_t create_symbol_hash_table (void)
 
static struct mapped_symtabcreate_mapped_symtab (void)
 
static void cleanup_mapped_symtab (void *p)
 
static struct symtab_index_entry ** find_slot (struct mapped_symtab *symtab, const char *name)
 
static void hash_expand (struct mapped_symtab *symtab)
 
static void add_index_entry (struct mapped_symtab *symtab, const char *name, int is_static, gdb_index_symbol_kind kind, offset_type cu_index)
 
static int offset_type_compare (const void *ap, const void *bp)
 
static void uniquify_cu_indices (struct mapped_symtab *symtab)
 
static offset_type add_indices_to_cpool (htab_t symbol_hash_table, struct obstack *cpool, struct symtab_index_entry *entry)
 
static void write_hash_table (struct mapped_symtab *symtab, struct obstack *output, struct obstack *cpool)
 
static hashval_t hash_psymtab_cu_index (const void *item)
 
static int eq_psymtab_cu_index (const void *item_lhs, const void *item_rhs)
 
static void add_address_entry (struct objfile *objfile, struct obstack *obstack, CORE_ADDR start, CORE_ADDR end, unsigned int cu_index)
 
static int add_address_entry_worker (void *datap, CORE_ADDR start_addr, void *obj)
 
static void write_address_map (struct objfile *objfile, struct obstack *obstack, htab_t cu_index_htab)
 
static gdb_index_symbol_kind symbol_kind (struct partial_symbol *psym)
 
static void write_psymbols (struct mapped_symtab *symtab, htab_t psyms_seen, struct partial_symbol **psymp, int count, offset_type cu_index, int is_static)
 
static void write_obstack (FILE *file, struct obstack *obstack)
 
static void unlink_if_set (void *p)
 
static int write_one_signatured_type (void **slot, void *d)
 
static void recursively_write_psymbols (struct objfile *objfile, struct partial_symtab *psymtab, struct mapped_symtab *symtab, htab_t psyms_seen, offset_type cu_index)
 
static void write_psymtabs_to_index (struct objfile *objfile, const char *dir)
 
static void save_gdb_index_command (char *arg, int from_tty)
 
static void show_dwarf_always_disassemble (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static void show_check_physname (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
void _initialize_dwarf2_read (void)
 

Variables

static unsigned int dwarf_read_debug = 0
 
static unsigned int dwarf_die_debug = 0
 
static unsigned int dwarf_line_debug = 0
 
static int check_physname = 0
 
static int use_deprecated_index_sections = 0
 
static const struct objfile_data * dwarf2_objfile_data_key
 
static int dwarf2_locexpr_index
 
static int dwarf2_loclist_index
 
static int dwarf2_locexpr_block_index
 
static int dwarf2_loclist_block_index
 
static struct dwarf2_per_objfiledwarf2_per_objfile
 
static const struct dwarf2_debug_sections dwarf2_elf_names
 
static const struct dwop_section_names dwop_section_names
 
static int bits_per_byte = 8
 
static struct dwarf2_queue_itemdwarf2_queue
 
static struct dwarf2_queue_itemdwarf2_queue_tail
 
static int dwarf_max_cache_age = 5
 
const struct quick_symbol_functions dwarf2_gdb_index_functions
 
static struct cmd_list_elementset_dwarf_cmdlist
 
static struct cmd_list_elementshow_dwarf_cmdlist
 
int dwarf_always_disassemble
 

Macro Definition Documentation

#define ABBREV_HASH_SIZE   121
#define ATTR_ALLOC_CHUNK   4

Definition at line 1287 of file dwarf2read.c.

Referenced by abbrev_table_read_table().

#define DW2_GDB_INDEX_CU_SET_VALUE (   cu_index,
  value 
)
Value:
do { \
gdb_assert (((value) & ~GDB_INDEX_CU_MASK) == 0); \
GDB_INDEX_CU_SET_VALUE((cu_index), (value)); \
} while (0)
Definition: value.c:172

Definition at line 170 of file dwarf2read.c.

Referenced by add_index_entry().

#define DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE (   cu_index,
  value 
)
Value:
do { \
gdb_assert ((value) >= GDB_INDEX_SYMBOL_KIND_TYPE \
&& (value) <= GDB_INDEX_SYMBOL_KIND_OTHER); \
GDB_INDEX_SYMBOL_KIND_SET_VALUE((cu_index), (value)); \
} while (0)
Definition: value.c:172

Definition at line 162 of file dwarf2read.c.

Referenced by add_index_entry().

#define DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE (   cu_index,
  value 
)
Value:
do { \
gdb_assert ((unsigned int) (value) <= 1); \
GDB_INDEX_SYMBOL_STATIC_SET_VALUE((cu_index), (value)); \
} while (0)
Definition: value.c:172

Definition at line 155 of file dwarf2read.c.

Referenced by add_index_entry().

#define DW_ADDR (   attr)    ((attr)->u.addr)
#define DW_BLOCK (   attr)    ((attr)->u.blk)
#define DW_FIELD_ALLOC_CHUNK   4

Definition at line 1292 of file dwarf2read.c.

Referenced by dwarf2_add_member_fn(), process_enumeration_scope(), and read_array_type().

#define DW_SIGNATURE (   attr)    ((attr)->u.signature)
#define DW_SND (   attr)    ((attr)->u.snd)
#define DW_STRING (   attr)    ((attr)->u.str)
#define DW_STRING_IS_CANONICAL (   attr)    ((attr)->string_is_canonical)
#define DW_UNSND (   attr)    ((attr)->u.unsnd)
#define INDEX_SUFFIX   ".gdb-index"

Definition at line 2024 of file dwarf2read.c.

Referenced by write_psymtabs_to_index().

#define IS_TYPE_UNIT_GROUP (   per_cu)    ((per_cu)->section == NULL)
#define MAX_NESTED_IMPORTED_DECLARATIONS   100

Referenced by read_namespace_alias().

#define MAX_NR_V1_DWO_SECTIONS
Value:
(1 /* .debug_info or .debug_types */ \
+ 1 /* .debug_abbrev */ \
+ 1 /* .debug_line */ \
+ 1 /* .debug_loc */ \
+ 1 /* .debug_str_offsets */ \
+ 1 /* .debug_macro or .debug_macinfo */ \
+ 1 /* trailing zero */)

Referenced by create_dwo_unit_in_dwp_v1().

#define MAX_NR_V2_DWO_SECTIONS
Value:
(1 /* .debug_info or .debug_types */ \
+ 1 /* .debug_abbrev */ \
+ 1 /* .debug_line */ \
+ 1 /* .debug_loc */ \
+ 1 /* .debug_str_offsets */ \
+ 1 /* .debug_macro or .debug_macinfo */)

Definition at line 931 of file dwarf2read.c.

Referenced by create_dwp_hash_table().

#define MAX_SEP_LEN   7 /* strlen ("__") + strlen ("_MOD_") */

Definition at line 19373 of file dwarf2read.c.

Referenced by typename_concat().

#define MAYBE_SWAP (   V)    (V)
#define NO_STMT_LIST_TYPE_UNIT_PSYMTAB   (1 << 31)

Definition at line 5771 of file dwarf2read.c.

Referenced by create_type_unit_group(), and get_type_unit_group().

#define NO_STMT_LIST_TYPE_UNIT_PSYMTAB_SIZE   10

Definition at line 5772 of file dwarf2read.c.

Referenced by get_type_unit_group().

Typedef Documentation

Definition at line 424 of file dwarf2read.c.

typedef void( die_reader_func_ftype) (const struct die_reader_specs *reader, const gdb_byte *info_ptr, struct die_info *comp_unit_die, int has_children, void *data)

Definition at line 1024 of file dwarf2read.c.

Definition at line 202 of file dwarf2read.c.

Definition at line 145 of file dwarf2read.c.

typedef uint32_t offset_type

Definition at line 150 of file dwarf2read.c.

typedef struct signatured_type* sig_type_ptr

Definition at line 693 of file dwarf2read.c.

typedef struct symbol* symbolp

Definition at line 76 of file dwarf2read.c.

Enumeration Type Documentation

Enumerator
DW_SECT_MIN 

Definition at line 792 of file dwarf2read.c.

Function Documentation

void _initialize_dwarf2_read ( void  )
static void abbrev_table_add_abbrev ( struct abbrev_table abbrev_table,
unsigned int  abbrev_number,
struct abbrev_info abbrev 
)
static

Definition at line 15265 of file dwarf2read.c.

References ABBREV_HASH_SIZE, abbrev_table::abbrevs, and abbrev_info::next.

Referenced by abbrev_table_read_table().

static struct abbrev_info* abbrev_table_alloc_abbrev ( struct abbrev_table abbrev_table)
static

Definition at line 15252 of file dwarf2read.c.

References abbrev_table::abbrev_obstack.

Referenced by abbrev_table_read_table().

static void abbrev_table_free ( struct abbrev_table abbrev_table)
static
static void abbrev_table_free_cleanup ( void *  table_ptr)
static

Definition at line 15408 of file dwarf2read.c.

References abbrev_table_free().

Referenced by build_type_psymtabs_1().

static struct abbrev_info * abbrev_table_lookup_abbrev ( const struct abbrev_table abbrev_table,
unsigned int  abbrev_number 
)
static
static struct abbrev_table * abbrev_table_read_table ( struct dwarf2_section_info section,
sect_offset  offset 
)
static
static void add_address_entry ( struct objfile objfile,
struct obstack *  obstack,
CORE_ADDR  start,
CORE_ADDR  end,
unsigned int  cu_index 
)
static
static int add_address_entry_worker ( void *  datap,
CORE_ADDR  start_addr,
void *  obj 
)
static
static struct type* add_array_cv_type ( struct die_info die,
struct dwarf2_cu cu,
struct type base_type,
int  cnst,
int  voltl 
)
static
static void add_file_name ( struct line_header lh,
const char *  name,
unsigned int  dir_index,
unsigned int  mod_time,
unsigned int  length 
)
static
static void add_include_dir ( struct line_header lh,
const char *  include_dir 
)
static
static void add_index_entry ( struct mapped_symtab symtab,
const char *  name,
int  is_static,
gdb_index_symbol_kind  kind,
offset_type  cu_index 
)
static
static offset_type add_indices_to_cpool ( htab_t  symbol_hash_table,
struct obstack *  cpool,
struct symtab_index_entry entry 
)
static

Definition at line 22767 of file dwarf2read.c.

References symtab_index_entry::index_offset, len, MAYBE_SWAP, VEC_iterate, and VEC_length.

Referenced by write_hash_table().

static void add_partial_enumeration ( struct partial_die_info enum_pdi,
struct dwarf2_cu cu 
)
static
static void add_partial_module ( struct partial_die_info pdi,
CORE_ADDR lowpc,
CORE_ADDR highpc,
int  set_addrmap,
struct dwarf2_cu cu 
)
static
static void add_partial_namespace ( struct partial_die_info pdi,
CORE_ADDR lowpc,
CORE_ADDR highpc,
int  set_addrmap,
struct dwarf2_cu cu 
)
static
static void add_partial_subprogram ( struct partial_die_info pdi,
CORE_ADDR lowpc,
CORE_ADDR highpc,
int  need_pc,
struct dwarf2_cu cu 
)
static
static void add_partial_symbol ( struct partial_die_info pdi,
struct dwarf2_cu cu 
)
static
static int add_signatured_type_cu_to_table ( void **  slot,
void *  datum 
)
static

Definition at line 4574 of file dwarf2read.c.

Referenced by create_all_type_units().

static offset_type add_string ( htab_t  table,
struct obstack *  cpool,
const char *  str 
)
static

Definition at line 22513 of file dwarf2read.c.

References obstack_grow_str0, strtab_entry::offset, and strtab_entry::str.

Referenced by write_hash_table().

static void add_to_method_list ( struct type type,
int  fnfield_index,
int  index,
const char *  name,
struct die_info die,
struct dwarf2_cu cu 
)
static
static struct signatured_type* add_type_unit ( ULONGEST  sig,
void **  slot 
)
static
static void age_cached_comp_units ( void  )
static
static htab_t allocate_dwo_file_hash_table ( void  )
static
static htab_t allocate_dwo_unit_table ( struct objfile objfile)
static
static htab_t allocate_dwp_loaded_cutus_table ( struct objfile objfile)
static
static htab_t allocate_signatured_type_table ( struct objfile objfile)
static
static htab_t allocate_type_unit_groups_table ( void  )
static
static char* anonymous_struct_prefix ( struct die_info die,
struct dwarf2_cu cu 
)
static
static int attr_form_is_block ( const struct attribute attr)
static
static int attr_form_is_constant ( const struct attribute attr)
static
static int attr_form_is_ref ( const struct attribute attr)
static
static int attr_form_is_section_offset ( const struct attribute attr)
static
static int attr_to_dynamic_prop ( const struct attribute attr,
struct die_info die,
struct dwarf2_cu cu,
struct dynamic_prop prop 
)
static
static CORE_ADDR attr_value_as_address ( struct attribute attr)
static
static struct type* build_error_marker_type ( struct dwarf2_cu cu,
struct die_info die 
)
static
static int build_type_psymtab_dependencies ( void **  slot,
void *  info 
)
static
static void build_type_psymtabs ( struct objfile objfile)
static

Definition at line 6326 of file dwarf2read.c.

References build_type_psymtabs_1(), and create_all_type_units().

Referenced by dwarf2_build_psymtabs_hard().

static void build_type_psymtabs_1 ( void  )
static
static void build_type_psymtabs_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info type_unit_die,
int  has_children,
void *  data 
)
static
static void check_line_address ( struct dwarf2_cu cu,
lnp_state_machine state,
const gdb_byte line_ptr,
CORE_ADDR  lowpc,
CORE_ADDR  address 
)
static
static void check_producer ( struct dwarf2_cu cu)
static
static void cleanup_mapped_symtab ( void *  p)
static

Definition at line 22615 of file dwarf2read.c.

References mapped_symtab::data, and xfree().

Referenced by write_psymtabs_to_index().

static void compute_compunit_symtab_includes ( struct dwarf2_per_cu_data per_cu)
static
static void compute_delayed_physnames ( struct dwarf2_cu cu)
static
static const char* consume_improper_spaces ( const char *  p,
const char *  body 
)
static

Definition at line 20868 of file dwarf2read.c.

References _, complaint(), and symfile_complaints.

Referenced by parse_macro_definition().

static char* copy_string ( const char *  buf,
int  len 
)
static

Definition at line 20857 of file dwarf2read.c.

References len, and xmalloc().

Referenced by parse_macro_definition().

static void create_addrmap_from_index ( struct objfile objfile,
struct mapped_index index 
)
static
static void create_all_comp_units ( struct objfile objfile)
static
static int create_all_type_units ( struct objfile objfile)
static
static void create_cus_from_index ( struct objfile objfile,
const gdb_byte cu_list,
offset_type  cu_list_elements,
const gdb_byte dwz_list,
offset_type  dwz_elements 
)
static
static void create_cus_from_index_list ( struct objfile objfile,
const gdb_byte cu_list,
offset_type  n_elements,
struct dwarf2_section_info section,
int  is_dwz,
int  base_offset 
)
static
static htab_t create_debug_types_hash_table ( struct dwo_file dwo_file,
VEC(dwarf2_section_info_def)*  types 
)
static
static struct dwo_unit* create_dwo_cu ( struct dwo_file dwo_file)
static
static void create_dwo_cu_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  datap 
)
static
static struct dwo_unit* create_dwo_unit_in_dwp_v1 ( struct dwp_file dwp_file,
uint32_t  unit_index,
const char *  comp_dir,
ULONGEST  signature,
int  is_debug_types 
)
static
static struct dwo_unit* create_dwo_unit_in_dwp_v2 ( struct dwp_file dwp_file,
uint32_t  unit_index,
const char *  comp_dir,
ULONGEST  signature,
int  is_debug_types 
)
static

Definition at line 10203 of file dwarf2read.c.

References dwo_sections::abbrev, dwp_sections::abbrev, virtual_v2_dwo_sections::abbrev_offset, virtual_v2_dwo_sections::abbrev_size, dwo_file::comp_dir, create_dwp_v2_section(), dwp_file::cus, dwp_file::dbfd, do_cleanups(), dwarf_read_debug, dwo_unit::dwo_file, dwo_file::dwo_name, fprintf_unfiltered(), gdb_assert, gdb_stdlog, hex_string(), dwp_sections::info, virtual_v2_dwo_sections::info_or_types_offset, virtual_v2_dwo_sections::info_or_types_size, dwo_sections::line, dwp_sections::line, virtual_v2_dwo_sections::line_offset, virtual_v2_dwo_sections::line_size, dwo_sections::loc, dwp_sections::loc, virtual_v2_dwo_sections::loc_offset, virtual_v2_dwo_sections::loc_size, lookup_dwo_file_slot(), dwo_sections::macinfo, dwp_sections::macinfo, virtual_v2_dwo_sections::macinfo_offset, virtual_v2_dwo_sections::macinfo_size, dwo_sections::macro, dwp_sections::macro, virtual_v2_dwo_sections::macro_offset, virtual_v2_dwo_sections::macro_size, make_cleanup(), dwp_file::name, dwp_hash_table::nr_columns, null_cleanup(), objfile::objfile_obstack, OBSTACK_ZALLOC, offset, pulongest(), read_4_bytes(), dwo_unit::section, dwp_hash_table::section_pool, dwo_file::sections, dwp_file::sections, dwo_unit::signature, size, dwo_sections::str, dwp_sections::str, dwo_sections::str_offsets, dwp_sections::str_offsets, virtual_v2_dwo_sections::str_offsets_offset, virtual_v2_dwo_sections::str_offsets_size, dwp_file::tus, dwp_sections::types, dwp_hash_table::v2, dwp_file::version, xfree(), and xstrprintf().

Referenced by lookup_dwo_unit_in_dwp().

static struct dwp_hash_table* create_dwp_hash_table ( struct dwp_file dwp_file,
int  is_debug_types 
)
static
static struct dwarf2_section_info create_dwp_v2_section ( struct dwarf2_section_info section,
bfd_size_type  offset,
bfd_size_type  size 
)
static
static struct mapped_symtab* create_mapped_symtab ( void  )
static
static struct partial_symtab * create_partial_symtab ( struct dwarf2_per_cu_data per_cu,
const char *  name 
)
static
static htab_t create_quick_file_names_table ( unsigned int  nr_initial_entries)
static
static void create_signatured_type_table_from_index ( struct objfile objfile,
struct dwarf2_section_info section,
const gdb_byte bytes,
offset_type  elements 
)
static
static htab_t create_strtab ( void  )
static

Definition at line 22503 of file dwarf2read.c.

References eq_strtab_entry(), hash_strtab_entry(), xcalloc(), and xfree().

Referenced by write_hash_table().

static htab_t create_symbol_hash_table ( void  )
static

Definition at line 22594 of file dwarf2read.c.

References delete_symtab_entry(), eq_symtab_entry(), hash_symtab_entry(), xcalloc(), and xfree().

Referenced by write_hash_table().

static struct type_unit_group* create_type_unit_group ( struct dwarf2_cu cu,
sect_offset  line_offset_struct 
)
static
static struct dwarf2_section_info* cu_debug_loc_section ( struct dwarf2_cu cu)
static

Definition at line 21761 of file dwarf2read.c.

References dwarf2_per_objfile::loc.

Referenced by dwarf2_symbol_mark_computed(), and fill_in_loclist_baton().

static CORE_ADDR decode_locdesc ( struct dwarf_block blk,
struct dwarf2_cu cu 
)
static
DEF_VEC_I ( offset_type  )
DEF_VEC_O ( dwarf2_section_info_def  )
DEF_VEC_O ( delayed_method_info  )
DEF_VEC_P ( symbolp  )
DEF_VEC_P ( dwarf2_per_cu_ptr  )
DEF_VEC_P ( sig_type_ptr  )
static void delete_file_name_entry ( void *  e)
static
static void delete_symtab_entry ( void *  p)
static

Definition at line 22584 of file dwarf2read.c.

References VEC_free, and xfree().

Referenced by create_symbol_hash_table().

static const char * determine_prefix ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * die_containing_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * die_descriptive_type ( struct die_info die,
struct dwarf2_cu cu 
)
static

Definition at line 18862 of file dwarf2read.c.

References dwarf2_attr(), and lookup_die_type().

Referenced by set_descriptive_type().

static int die_eq ( const void *  item_lhs,
const void *  item_rhs 
)
static
static hashval_t die_hash ( const void *  item)
static
static int die_is_declaration ( struct die_info die,
struct dwarf2_cu cu 
)
static
static int die_needs_namespace ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct die_info * die_specification ( struct die_info die,
struct dwarf2_cu **  spec_cu 
)
static
static struct type * die_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void do_ui_file_peek_last ( void *  object,
const char *  buffer,
long  length 
)
static

Definition at line 8411 of file dwarf2read.c.

Referenced by dwarf2_compute_name().

void dump_die ( struct die_info die,
int  max_level 
)

Definition at line 19826 of file dwarf2read.c.

References dump_die_1(), and gdb_stdlog.

Referenced by read_cutu_die_from_dwo(), read_die_and_siblings(), and read_full_die().

static void dump_die_1 ( struct ui_file f,
int  level,
int  max_level,
struct die_info die 
)
static
static void dump_die_for_error ( struct die_info die)
static

Definition at line 19783 of file dwarf2read.c.

References dump_die_shallow(), and gdb_stderr.

Referenced by follow_die_ref_or_sig(), and follow_die_sig().

static void dump_die_shallow ( struct ui_file f,
int  indent,
struct die_info die 
)
static
static void dw2_do_instantiate_symtab ( struct dwarf2_per_cu_data per_cu)
static
static void dw2_dump ( struct objfile objfile)
static

Definition at line 3723 of file dwarf2read.c.

References dw2_setup(), gdb_assert, and printf_filtered().

static void dw2_expand_all_symtabs ( struct objfile objfile)
static

Definition at line 3772 of file dwarf2read.c.

References dw2_get_cutu(), dw2_instantiate_symtab(), and dw2_setup().

static void dw2_expand_symtabs_for_function ( struct objfile objfile,
const char *  func_name 
)
static
static void dw2_expand_symtabs_matching ( struct objfile objfile,
expand_symtabs_file_matcher_ftype file_matcher,
expand_symtabs_symbol_matcher_ftype symbol_matcher,
expand_symtabs_exp_notify_ftype expansion_notify,
enum search_domain  kind,
void *  data 
)
static
static void dw2_expand_symtabs_with_fullname ( struct objfile objfile,
const char *  fullname 
)
static
static struct symtab* dw2_find_last_source_symtab ( struct objfile objfile)
static
static struct compunit_symtab* dw2_find_pc_sect_compunit_symtab ( struct objfile objfile,
struct bound_minimal_symbol  msymbol,
CORE_ADDR  pc,
struct obj_section section,
int  warn_if_readin 
)
static
static void dw2_forget_cached_source_info ( struct objfile objfile)
static

Definition at line 3400 of file dwarf2read.c.

References dw2_free_cached_file_names(), and dw2_setup().

static int dw2_free_cached_file_names ( void **  slot,
void *  info 
)
static
static struct dwarf2_per_cu_data* dw2_get_cu ( int  index)
static
static struct dwarf2_per_cu_data* dw2_get_cutu ( int  index)
static
static struct quick_file_names* dw2_get_file_names ( struct dwarf2_per_cu_data this_cu)
static
static void dw2_get_file_names_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  data 
)
static
static const char* dw2_get_real_path ( struct objfile objfile,
struct quick_file_names qfn,
int  index 
)
static
static int dw2_has_symbols ( struct objfile objfile)
static

Definition at line 4166 of file dwarf2read.c.

static struct compunit_symtab* dw2_instantiate_symtab ( struct dwarf2_per_cu_data per_cu)
static
static struct compunit_symtab* dw2_lookup_symbol ( struct objfile objfile,
int  block_index,
const char *  name,
domain_enum  domain 
)
static
static int dw2_map_expand_apply ( struct objfile objfile,
struct dwarf2_per_cu_data per_cu,
const char *  name,
const char *  real_path,
int(*)(struct symtab *, void *)  callback,
void *  data 
)
static
static void dw2_map_matching_symbols ( struct objfile objfile,
const char *  name,
domain_enum  domain,
int  global,
int(*)(struct block *, struct symbol *, void *)  callback,
void *  data,
symbol_compare_ftype match,
symbol_compare_ftype ordered_compare 
)
static

Definition at line 3828 of file dwarf2read.c.

static void dw2_map_symbol_filenames ( struct objfile objfile,
symbol_filename_ftype fun,
void *  data,
int  need_fullname 
)
static
static int dw2_map_symtabs_matching_filename ( struct objfile objfile,
const char *  name,
const char *  real_path,
int(*)(struct symtab *, void *)  callback,
void *  data 
)
static
static void dw2_print_stats ( struct objfile objfile)
static
static void dw2_relocate ( struct objfile objfile,
const struct section_offsets new_offsets,
const struct section_offsets delta 
)
static

Definition at line 3739 of file dwarf2read.c.

static void dw2_setup ( struct objfile objfile)
static
static void dw2_symtab_iter_init ( struct dw2_symtab_iterator iter,
struct mapped_index index,
int  want_specific_block,
int  block_index,
domain_enum  domain,
const char *  name 
)
static
static struct dwarf2_per_cu_data* dw2_symtab_iter_next ( struct dw2_symtab_iterator iter)
static
static void dwarf2_add_dependence ( struct dwarf2_cu cu,
struct dwarf2_per_cu_data ref_per_cu 
)
static
static void dwarf2_add_field ( struct field_info fip,
struct die_info die,
struct dwarf2_cu cu 
)
static
static void dwarf2_add_member_fn ( struct field_info fip,
struct die_info die,
struct type type,
struct dwarf2_cu cu 
)
static
static void dwarf2_add_typedef ( struct field_info fip,
struct die_info die,
struct dwarf2_cu cu 
)
static
static void dwarf2_attach_fields_to_type ( struct field_info fip,
struct type type,
struct dwarf2_cu cu 
)
static
static void dwarf2_attach_fn_fields_to_type ( struct field_info fip,
struct type type,
struct dwarf2_cu cu 
)
static
static struct attribute * dwarf2_attr ( struct die_info die,
unsigned int  name,
struct dwarf2_cu cu 
)
static

Definition at line 17029 of file dwarf2read.c.

References die_info::attrs, follow_die_ref(), attribute::name, and die_info::num_attrs.

Referenced by anonymous_struct_prefix(), attr_to_dynamic_prop(), create_dwo_cu_reader(), die_containing_type(), die_descriptive_type(), die_is_declaration(), die_needs_namespace(), die_specification(), die_type(), dw2_get_file_names_reader(), dwarf2_add_field(), dwarf2_add_member_fn(), dwarf2_build_include_psymtabs(), dwarf2_compute_name(), dwarf2_extension(), dwarf2_fetch_constant_bytes(), dwarf2_fetch_die_loc_sect_off(), dwarf2_find_base_address(), dwarf2_flag_true_p(), dwarf2_get_pc_bounds(), dwarf2_name(), dwarf2_physname(), dwarf2_record_block_ranges(), find_file_and_directory(), guess_full_die_structure_name(), handle_data_member_location(), handle_DW_AT_stmt_list(), inherit_abstract_dies(), init_cutu_and_read_dies(), lookup_dwo_unit(), namespace_name(), new_symbol_full(), prepare_one_comp_unit(), process_imported_unit_die(), process_psymtab_comp_unit_reader(), process_structure_scope(), prototyped_function_p(), read_array_order(), read_array_type(), read_base_type(), read_call_site_scope(), read_common_block(), read_cutu_die_from_dwo(), read_enumeration_type(), read_file_scope(), read_func_scope(), read_import_statement(), read_namespace(), read_namespace_alias(), read_namespace_type(), read_set_type(), read_structure_type(), read_subrange_type(), read_subroutine_type(), read_tag_pointer_type(), read_tag_reference_type(), read_tag_string_type(), set_die_type(), setup_type_unit_groups(), and update_enumeration_type_from_children().

static struct attribute * dwarf2_attr_no_follow ( struct die_info die,
unsigned int  name 
)
static
static void dwarf2_build_include_psymtabs ( struct dwarf2_cu cu,
struct die_info die,
struct partial_symtab pst 
)
static
void dwarf2_build_psymtabs ( struct objfile objfile)
static void dwarf2_build_psymtabs_hard ( struct objfile objfile)
static
static const char * dwarf2_canonicalize_name ( const char *  name,
struct dwarf2_cu cu,
struct obstack *  obstack 
)
static
static void dwarf2_clear_marks ( struct dwarf2_per_cu_data per_cu)
static

Definition at line 22388 of file dwarf2read.c.

References dwarf2_per_cu_data::cu, and dwarf2_cu::read_in_chain.

Referenced by age_cached_comp_units().

static void dwarf2_complex_location_expr_complaint ( void  )
static
static const char* dwarf2_compute_name ( const char *  name,
struct die_info die,
struct dwarf2_cu cu,
int  physname 
)
static
static void dwarf2_const_value ( const struct attribute attr,
struct symbol sym,
struct dwarf2_cu cu 
)
static
static void dwarf2_const_value_attr ( const struct attribute attr,
struct type type,
const char *  name,
struct obstack *  obstack,
struct dwarf2_cu cu,
LONGEST value,
const gdb_byte **  bytes,
struct dwarf2_locexpr_baton **  baton 
)
static
static gdb_byte* dwarf2_const_value_data ( const struct attribute attr,
struct obstack *  obstack,
struct dwarf2_cu cu,
LONGEST value,
int  bits 
)
static
static void dwarf2_const_value_length_mismatch_complaint ( const char *  arg1,
int  arg2,
int  arg3 
)
static

Definition at line 1906 of file dwarf2read.c.

References _, complaint(), and symfile_complaints.

Referenced by dwarf2_const_value_attr().

static void dwarf2_create_include_psymtab ( const char *  name,
struct partial_symtab pst,
struct objfile objfile 
)
static
static void dwarf2_debug_line_missing_end_sequence_complaint ( void  )
static

Definition at line 1892 of file dwarf2read.c.

References _, complaint(), and symfile_complaints.

Referenced by dwarf_decode_lines_1().

static void dwarf2_debug_line_missing_file_complaint ( void  )
static

Definition at line 1885 of file dwarf2read.c.

References _, complaint(), and symfile_complaints.

Referenced by dwarf_decode_lines_1(), and dwarf_record_line().

static enum dwarf_access_attribute dwarf2_default_access_attribute ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct die_info * dwarf2_extension ( struct die_info die,
struct dwarf2_cu **  ext_cu 
)
static

Definition at line 19586 of file dwarf2read.c.

References dwarf2_attr(), and follow_die_ref().

Referenced by namespace_name(), and read_namespace_type().

const gdb_byte* dwarf2_fetch_constant_bytes ( sect_offset  offset,
struct dwarf2_per_cu_data per_cu,
struct obstack *  obstack,
LONGEST len 
)
struct dwarf2_locexpr_baton dwarf2_fetch_die_loc_cu_off ( cu_offset  offset_in_cu,
struct dwarf2_per_cu_data per_cu,
CORE_ADDR(*)(void *baton)  get_frame_pc,
void *  baton 
)
struct dwarf2_locexpr_baton dwarf2_fetch_die_loc_sect_off ( sect_offset  offset,
struct dwarf2_per_cu_data per_cu,
CORE_ADDR(*)(void *baton)  get_frame_pc,
void *  baton 
)
static void dwarf2_find_base_address ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct dwarf2_per_cu_data * dwarf2_find_containing_comp_unit ( sect_offset  offset,
unsigned int  offset_in_dwz,
struct objfile objfile 
)
static
static int dwarf2_flag_true_p ( struct die_info die,
unsigned  name,
struct dwarf2_cu cu 
)
static
static void dwarf2_free_abbrev_table ( void *  ptr_to_cu)
static
void dwarf2_free_objfile ( struct objfile objfile)
static const char * dwarf2_full_name ( const char *  name,
struct die_info die,
struct dwarf2_cu cu 
)
static
static LONGEST dwarf2_get_attr_constant_value ( const struct attribute attr,
int  default_value 
)
static
struct type* dwarf2_get_die_type ( cu_offset  die_offset,
struct dwarf2_per_cu_data per_cu 
)
static struct dwz_file* dwarf2_get_dwz_file ( void  )
static
static int dwarf2_get_pc_bounds ( struct die_info die,
CORE_ADDR lowpc,
CORE_ADDR highpc,
struct dwarf2_cu cu,
struct partial_symtab pst 
)
static
static sect_offset dwarf2_get_ref_die_offset ( const struct attribute attr)
static
void dwarf2_get_section_info ( struct objfile objfile,
enum dwarf2_section_enum  sect,
asection **  sectp,
const gdb_byte **  bufp,
bfd_size_type *  sizep 
)
static void dwarf2_get_subprogram_pc_bounds ( struct die_info die,
CORE_ADDR lowpc,
CORE_ADDR highpc,
struct dwarf2_cu cu 
)
static
int dwarf2_has_info ( struct objfile objfile,
const struct dwarf2_debug_sections names 
)
int dwarf2_initialize_objfile ( struct objfile objfile)
static void dwarf2_invalid_attrib_class_complaint ( const char *  arg1,
const char *  arg2 
)
static
static int dwarf2_is_constructor ( struct die_info die,
struct dwarf2_cu cu 
)
static

Definition at line 12754 of file dwarf2read.c.

References dwarf2_name(), len, die_info::parent, and die_info::tag.

Referenced by dwarf2_add_member_fn().

static void dwarf2_locate_common_dwp_sections ( bfd *  abfd,
asection *  sectp,
void *  dwp_file_ptr 
)
static
static void dwarf2_locate_dwo_sections ( bfd *  abfd,
asection *  sectp,
void *  dwo_sections_ptr 
)
static
static void dwarf2_locate_sections ( bfd *  abfd,
asection *  sectp,
void *  vnames 
)
static
static void dwarf2_locate_v2_dwp_sections ( bfd *  abfd,
asection *  sectp,
void *  dwp_file_ptr 
)
static
static void dwarf2_macro_malformed_definition_complaint ( const char *  arg1)
static

Definition at line 1925 of file dwarf2read.c.

References _, complaint(), and symfile_complaints.

Referenced by parse_macro_definition().

static void dwarf2_mark ( struct dwarf2_cu cu)
static

Definition at line 22378 of file dwarf2read.c.

References dwarf2_cu::dependencies, and dwarf2_mark_helper().

Referenced by age_cached_comp_units().

static int dwarf2_mark_helper ( void **  slot,
void *  data 
)
static

Definition at line 22352 of file dwarf2read.c.

References dwarf2_per_cu_data::cu, and dwarf2_cu::dependencies.

Referenced by dwarf2_mark().

static const char * dwarf2_name ( struct die_info die,
struct dwarf2_cu cu 
)
static
int dwarf2_per_cu_addr_size ( struct dwarf2_per_cu_data per_cu)
struct objfile* dwarf2_per_cu_objfile ( struct dwarf2_per_cu_data per_cu)
int dwarf2_per_cu_offset_size ( struct dwarf2_per_cu_data per_cu)
int dwarf2_per_cu_ref_addr_size ( struct dwarf2_per_cu_data per_cu)
CORE_ADDR dwarf2_per_cu_text_offset ( struct dwarf2_per_cu_data per_cu)
static void dwarf2_per_objfile_free ( struct objfile objfile,
void *  d 
)
static

Definition at line 22439 of file dwarf2read.c.

References free_dwo_files(), gdb_bfd_unref(), VEC_free, and xfree().

Referenced by _initialize_dwarf2_read().

static const char * dwarf2_physname ( const char *  name,
struct die_info die,
struct dwarf2_cu cu 
)
static
static int dwarf2_ranges_read ( unsigned  offset,
CORE_ADDR low_return,
CORE_ADDR high_return,
struct dwarf2_cu cu,
struct partial_symtab ranges_pst 
)
static
static void dwarf2_read_abbrevs ( struct dwarf2_cu cu,
struct dwarf2_section_info abbrev_section 
)
static
CORE_ADDR dwarf2_read_addr_index ( struct dwarf2_per_cu_data per_cu,
unsigned int  addr_index 
)
static void dwarf2_read_addr_index_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  data 
)
static
static int dwarf2_read_index ( struct objfile objfile)
static
static void dwarf2_read_section ( struct objfile objfile,
struct dwarf2_section_info info 
)
static
static void dwarf2_read_symtab ( struct partial_symtab self,
struct objfile objfile 
)
static
static void dwarf2_record_block_ranges ( struct die_info die,
struct block block,
CORE_ADDR  baseaddr,
struct dwarf2_cu cu 
)
static
static void dwarf2_release_queue ( void *  dummy)
static
static void dwarf2_section_buffer_overflow_complaint ( struct dwarf2_section_info section)
static
static int dwarf2_section_empty_p ( const struct dwarf2_section_info section)
static
static bfd_size_type dwarf2_section_size ( struct objfile objfile,
struct dwarf2_section_info info 
)
static
static void dwarf2_start_subfile ( const char *  filename,
const char *  dirname 
)
static
static struct compunit_symtab * dwarf2_start_symtab ( struct dwarf2_cu cu,
const char *  name,
const char *  comp_dir,
CORE_ADDR  low_pc 
)
static
static void dwarf2_statement_list_fits_in_line_number_section_complaint ( void  )
static

Definition at line 1878 of file dwarf2read.c.

References _, complaint(), and symfile_complaints.

Referenced by dwarf_decode_line_header().

static void dwarf2_symbol_mark_computed ( const struct attribute attr,
struct symbol sym,
struct dwarf2_cu cu,
int  is_block 
)
static
static struct dwarf_block * dwarf_alloc_block ( struct dwarf2_cu cu)
static

Definition at line 20741 of file dwarf2read.c.

References dwarf2_cu::comp_unit_obstack.

Referenced by read_attribute_value().

static struct die_info * dwarf_alloc_die ( struct dwarf2_cu cu,
int  num_attrs 
)
static

Definition at line 20751 of file dwarf2read.c.

References dwarf2_cu::comp_unit_obstack, and size.

Referenced by read_full_die_1().

static const char * dwarf_attr_name ( unsigned  int)
static

Definition at line 19613 of file dwarf2read.c.

References name.

Referenced by dump_die_shallow(), and lookup_die_type().

static char * dwarf_bool_name ( unsigned  int)
static

Definition at line 19647 of file dwarf2read.c.

Referenced by dump_die_shallow().

static struct line_header * dwarf_decode_line_header ( unsigned int  offset,
struct dwarf2_cu cu 
)
static
static void dwarf_decode_lines ( struct line_header lh,
const char *  comp_dir,
struct dwarf2_cu cu,
struct partial_symtab pst,
CORE_ADDR  lowpc,
int  decode_mapping 
)
static
static void dwarf_decode_lines_1 ( struct line_header lh,
struct dwarf2_cu cu,
const int  decode_for_pst_p,
CORE_ADDR  lowpc 
)
static
static void dwarf_decode_macro_bytes ( bfd *  abfd,
const gdb_byte mac_ptr,
const gdb_byte mac_end,
struct macro_source_file current_file,
struct line_header lh,
struct dwarf2_section_info section,
int  section_is_gnu,
int  section_is_dwz,
unsigned int  offset_size,
htab_t  include_hash 
)
static
static void dwarf_decode_macros ( struct dwarf2_cu cu,
unsigned int  offset,
int  section_is_gnu 
)
static
static void dwarf_finish_line ( struct gdbarch gdbarch,
struct subfile subfile,
CORE_ADDR  address,
record_line_ftype  p_record_line 
)
static
static const char * dwarf_form_name ( unsigned  int)
static
static const gdb_byte* dwarf_parse_macro_header ( const gdb_byte **  opcode_definitions,
bfd *  abfd,
const gdb_byte mac_ptr,
unsigned int offset_size,
int  section_is_gnu 
)
static
static void dwarf_record_line ( lnp_reader_state reader,
lnp_state_machine state,
int  end_sequence 
)
static
static void dwarf_record_line_1 ( struct gdbarch gdbarch,
struct subfile subfile,
unsigned int  line,
CORE_ADDR  address,
record_line_ftype  p_record_line 
)
static
static int dwarf_record_line_p ( unsigned int  line,
unsigned int  last_line,
int  line_has_non_zero_discriminator,
struct subfile last_subfile 
)
static

Definition at line 17563 of file dwarf2read.c.

References current_subfile.

Referenced by dwarf_record_line().

static const char * dwarf_tag_name ( unsigned  int)
static
static const char * dwarf_type_encoding_name ( unsigned  int)
static

Definition at line 19658 of file dwarf2read.c.

References name.

Referenced by read_base_type().

static int eq_dwo_file ( const void *  item_lhs,
const void *  item_rhs 
)
static

Definition at line 9416 of file dwarf2read.c.

References dwo_file::comp_dir, and dwo_file::dwo_name.

Referenced by allocate_dwo_file_hash_table().

static int eq_dwo_unit ( const void *  item_lhs,
const void *  item_rhs 
)
static

Definition at line 9473 of file dwarf2read.c.

References dwo_unit::signature.

Referenced by allocate_dwo_unit_table().

static int eq_dwp_loaded_cutus ( const void *  a,
const void *  b 
)
static

Definition at line 10751 of file dwarf2read.c.

References dwo_unit::signature.

Referenced by allocate_dwp_loaded_cutus_table().

static int eq_file_name_entry ( const void *  a,
const void *  b 
)
static

Definition at line 2609 of file dwarf2read.c.

References eq_stmt_list_entry(), and quick_file_names::hash.

Referenced by create_quick_file_names_table().

static int eq_psymtab_cu_index ( const void *  item_lhs,
const void *  item_rhs 
)
static

Definition at line 22868 of file dwarf2read.c.

References psymtab_cu_index_map::psymtab.

Referenced by write_psymtabs_to_index().

static int eq_signatured_type ( const void *  item_lhs,
const void *  item_rhs 
)
static

Definition at line 4549 of file dwarf2read.c.

References signatured_type::signature.

Referenced by allocate_signatured_type_table().

static int eq_stmt_list_entry ( const struct stmt_list_hash lhs,
const struct stmt_list_hash rhs 
)
static
static int eq_strtab_entry ( const void *  a,
const void *  b 
)
static

Definition at line 22493 of file dwarf2read.c.

References strtab_entry::str.

Referenced by create_strtab().

static int eq_symtab_entry ( const void *  a,
const void *  b 
)
static

Definition at line 22569 of file dwarf2read.c.

References len, VEC_address, and VEC_length.

Referenced by create_symbol_hash_table().

static int eq_type_unit_group ( const void *  item_lhs,
const void *  item_rhs 
)
static

Definition at line 5746 of file dwarf2read.c.

References eq_stmt_list_entry().

Referenced by allocate_type_unit_groups_table().

static void error_check_comp_unit_head ( struct comp_unit_head header,
struct dwarf2_section_info section,
struct dwarf2_section_info abbrev_section 
)
static
static char* file_file_name ( int  file,
struct line_header lh 
)
static
static char * file_full_name ( int  file,
struct line_header lh,
const char *  comp_dir 
)
static

Definition at line 20809 of file dwarf2read.c.

References file_file_name(), and SLASH_STRING.

Referenced by dw2_get_file_names_reader().

static void fill_in_loclist_baton ( struct dwarf2_cu cu,
struct dwarf2_loclist_baton baton,
const struct attribute attr 
)
static
static void fill_in_sig_entry_from_dwo_entry ( struct objfile objfile,
struct signatured_type sig_entry,
struct dwo_unit dwo_entry 
)
static
static void find_file_and_directory ( struct die_info die,
struct dwarf2_cu cu,
const char **  name,
const char **  comp_dir 
)
static
static struct partial_die_info * find_partial_die ( sect_offset  offset,
int  offset_in_dwz,
struct dwarf2_cu cu 
)
static
static struct partial_die_info* find_partial_die_in_comp_unit ( sect_offset  offset,
struct dwarf2_cu cu 
)
static
static struct symtab_index_entry** find_slot ( struct mapped_symtab symtab,
const char *  name 
)
static
static int find_slot_in_mapped_hash ( struct mapped_index index,
const char *  name,
offset_type **  vec_out 
)
static
static void fixup_go_packaging ( struct dwarf2_cu cu)
static
static void fixup_partial_die ( struct partial_die_info part_die,
struct dwarf2_cu cu 
)
static
static struct die_info* follow_die_offset ( sect_offset  offset,
int  offset_in_dwz,
struct dwarf2_cu **  ref_cu 
)
static
static struct die_info * follow_die_ref ( struct die_info src_die,
const struct attribute attr,
struct dwarf2_cu **  ref_cu 
)
static
static struct die_info * follow_die_ref_or_sig ( struct die_info src_die,
const struct attribute attr,
struct dwarf2_cu **  ref_cu 
)
static
static struct die_info * follow_die_sig ( struct die_info src_die,
const struct attribute attr,
struct dwarf2_cu **  ref_cu 
)
static
static struct die_info* follow_die_sig_1 ( struct die_info src_die,
struct signatured_type sig_type,
struct dwarf2_cu **  ref_cu 
)
static
static void free_cached_comp_units ( void *  data)
static
static void free_cu_line_header ( void *  arg)
static

Definition at line 9009 of file dwarf2read.c.

References free_line_header(), and dwarf2_cu::line_header.

Referenced by handle_DW_AT_stmt_list(), and setup_type_unit_groups().

static void free_delayed_list ( void *  ptr)
static

Definition at line 7763 of file dwarf2read.c.

References VEC_free.

Referenced by process_full_comp_unit(), and process_full_type_unit().

static void free_dwo_file ( struct dwo_file dwo_file,
struct objfile objfile 
)
static
static void free_dwo_file_cleanup ( void *  arg)
static

Definition at line 11128 of file dwarf2read.c.

References free_dwo_file().

Referenced by open_and_init_dwo_file().

static int free_dwo_file_from_slot ( void **  slot,
void *  info 
)
static

Definition at line 11139 of file dwarf2read.c.

References free_dwo_file().

Referenced by free_dwo_files().

static void free_dwo_files ( htab_t  dwo_files,
struct objfile objfile 
)
static

Definition at line 11152 of file dwarf2read.c.

References free_dwo_file_from_slot().

Referenced by dwarf2_per_objfile_free().

static void free_heap_comp_unit ( void *  data)
static
static void free_line_header ( struct line_header lh)
static
static void free_line_header_voidp ( void *  arg)
static

Definition at line 17144 of file dwarf2read.c.

References free_line_header().

Referenced by handle_DW_AT_stmt_list().

static void free_one_cached_comp_unit ( struct dwarf2_per_cu_data target_per_cu)
static
static void free_stack_comp_unit ( void *  data)
static
static struct dwarf2_section_info* get_abbrev_section_for_cu ( struct dwarf2_per_cu_data this_cu)
static
static struct compunit_symtab* get_compunit_symtab ( struct dwarf2_per_cu_data per_cu)
static
static struct dwarf2_section_info* get_containing_section ( const struct dwarf2_section_info section)
static
static unsigned int get_cu_length ( const struct comp_unit_head header)
static
static struct dwarf2_section_info* get_debug_line_section ( struct dwarf2_cu cu)
static
static struct type * get_die_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * get_die_type_at_offset ( sect_offset  offset,
struct dwarf2_per_cu_data per_cu 
)
static
static struct type * get_DW_AT_signature_type ( struct die_info die,
const struct attribute attr,
struct dwarf2_cu cu 
)
static
static struct dwp_file * get_dwp_file ( void  )
static
static void get_scope_pc_bounds ( struct die_info die,
CORE_ADDR lowpc,
CORE_ADDR highpc,
struct dwarf2_cu cu 
)
static
static struct bfd* get_section_bfd_owner ( const struct dwarf2_section_info section)
static
static asection* get_section_bfd_section ( const struct dwarf2_section_info section)
static
static const char * get_section_file_name ( const struct dwarf2_section_info section)
static
static int get_section_flags ( const struct dwarf2_section_info section)
static

Definition at line 2130 of file dwarf2read.c.

References gdb_assert, and get_section_bfd_section().

Referenced by read_index_from_section().

static int get_section_id ( const struct dwarf2_section_info section)
static

Definition at line 2117 of file dwarf2read.c.

References get_section_bfd_section().

Referenced by create_dwo_unit_in_dwp_v1().

static const char * get_section_name ( const struct dwarf2_section_info section)
static
static struct type * get_signatured_type ( struct die_info die,
ULONGEST  signature,
struct dwarf2_cu cu 
)
static
static struct type_unit_group* get_type_unit_group ( struct dwarf2_cu cu,
const struct attribute stmt_list 
)
static
static char* guess_full_die_structure_name ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void guess_partial_die_structure_name ( struct partial_die_info struct_pdi,
struct dwarf2_cu cu 
)
static
static int handle_data_member_location ( struct die_info die,
struct dwarf2_cu cu,
LONGEST offset 
)
static
static void handle_DW_AT_stmt_list ( struct die_info die,
struct dwarf2_cu cu,
const char *  comp_dir,
CORE_ADDR  lowpc 
)
static
static hashval_t hash_dwo_file ( const void *  item)
static

Definition at line 9404 of file dwarf2read.c.

References dwo_file::comp_dir, dwo_file::dwo_name, and hash().

Referenced by allocate_dwo_file_hash_table().

static hashval_t hash_dwo_unit ( const void *  item)
static

Definition at line 9464 of file dwarf2read.c.

References dwo_unit::signature.

Referenced by allocate_dwo_unit_table().

static hashval_t hash_dwp_loaded_cutus ( const void *  item)
static

Definition at line 10740 of file dwarf2read.c.

References dwo_unit::signature.

Referenced by allocate_dwp_loaded_cutus_table().

static void hash_expand ( struct mapped_symtab symtab)
static

Definition at line 22649 of file dwarf2read.c.

References mapped_symtab::data, find_slot(), mapped_symtab::size, and xfree().

Referenced by add_index_entry().

static hashval_t hash_file_name_entry ( const void *  e)
static

Definition at line 2599 of file dwarf2read.c.

References quick_file_names::hash, and hash_stmt_list_entry().

Referenced by create_quick_file_names_table().

static hashval_t hash_psymtab_cu_index ( const void *  item)
static

Definition at line 22860 of file dwarf2read.c.

References psymtab_cu_index_map::psymtab.

Referenced by write_psymtabs_to_index().

static hashval_t hash_signatured_type ( const void *  item)
static

Definition at line 4540 of file dwarf2read.c.

References signatured_type::signature.

Referenced by allocate_signatured_type_table().

static hashval_t hash_stmt_list_entry ( const struct stmt_list_hash stmt_list_hash)
static
static hashval_t hash_strtab_entry ( const void *  e)
static

Definition at line 22484 of file dwarf2read.c.

References INT_MAX, mapped_index_string_hash(), and strtab_entry::str.

Referenced by create_strtab().

static hashval_t hash_symtab_entry ( const void *  e)
static

Definition at line 22557 of file dwarf2read.c.

References VEC_address, and VEC_length.

Referenced by create_symbol_hash_table().

static hashval_t hash_type_unit_group ( const void *  item)
static

Definition at line 5738 of file dwarf2read.c.

References hash_stmt_list_entry().

Referenced by allocate_type_unit_groups_table().

static void inherit_abstract_dies ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void init_cu_die_reader ( struct die_reader_specs reader,
struct dwarf2_cu cu,
struct dwarf2_section_info section,
struct dwo_file dwo_file 
)
static
static void init_cutu_and_read_dies ( struct dwarf2_per_cu_data this_cu,
struct abbrev_table abbrev_table,
int  use_existing_cu,
int  keep,
die_reader_func_ftype die_reader_func,
void *  data 
)
static
static void init_cutu_and_read_dies_no_follow ( struct dwarf2_per_cu_data this_cu,
struct dwo_file dwo_file,
die_reader_func_ftype die_reader_func,
void *  data 
)
static
static void init_cutu_and_read_dies_simple ( struct dwarf2_per_cu_data this_cu,
die_reader_func_ftype die_reader_func,
void *  data 
)
static

Definition at line 5722 of file dwarf2read.c.

References init_cutu_and_read_dies_no_follow().

Referenced by dw2_get_file_names().

static void init_lnp_state_machine ( lnp_state_machine state,
const lnp_reader_state reader 
)
static
static void init_one_comp_unit ( struct dwarf2_cu cu,
struct dwarf2_per_cu_data per_cu 
)
static
static void init_tu_and_read_dwo_dies ( struct dwarf2_per_cu_data this_cu,
int  use_existing_cu,
int  keep,
die_reader_func_ftype die_reader_func,
void *  data 
)
static
static int is_type_tag_for_partial ( int  tag)
static

Definition at line 15445 of file dwarf2read.c.

Referenced by load_partial_dies().

static int is_vtable_name ( const char *  name,
struct dwarf2_cu cu 
)
static

Definition at line 13031 of file dwarf2read.c.

References is_cplus_marker(), dwarf2_cu::language, language_java, and startswith().

Referenced by process_structure_scope().

static int leb128_size ( const gdb_byte buf)
static

Definition at line 16955 of file dwarf2read.c.

Referenced by locexpr_describe_location_piece(), and var_decode_location().

static int line_header_eq_voidp ( const void *  item_lhs,
const void *  item_rhs 
)
static
static hashval_t line_header_hash ( const struct line_header ofs)
static
static hashval_t line_header_hash_voidp ( const void *  item)
static

Definition at line 1952 of file dwarf2read.c.

References line_header_hash().

Referenced by handle_DW_AT_stmt_list().

static void load_cu ( struct dwarf2_per_cu_data per_cu)
static
static void load_full_comp_unit ( struct dwarf2_per_cu_data this_cu,
enum language  pretend_language 
)
static
static void load_full_comp_unit_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  data 
)
static
static void load_full_type_unit ( struct dwarf2_per_cu_data per_cu)
static
static void load_partial_comp_unit ( struct dwarf2_per_cu_data this_cu)
static

Definition at line 6533 of file dwarf2read.c.

References init_cutu_and_read_dies(), and load_partial_comp_unit_reader().

Referenced by find_partial_die().

static void load_partial_comp_unit_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  data 
)
static
static struct partial_die_info * load_partial_dies ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
int  building_psymtab 
)
static
static void locate_dwz_sections ( bfd *  abfd,
asection *  sectp,
void *  arg 
)
static
static const gdb_byte* locate_pdi_sibling ( const struct die_reader_specs reader,
struct partial_die_info orig_pdi,
const gdb_byte info_ptr 
)
static
static int locate_v1_virtual_dwo_sections ( asection *  sectp,
struct virtual_v1_dwo_sections sections 
)
static
static struct type * lookup_die_type ( struct die_info die,
const struct attribute attr,
struct dwarf2_cu cu 
)
static
static struct dwo_unit * lookup_dwo_comp_unit ( struct dwarf2_per_cu_data this_cu,
const char *  dwo_name,
const char *  comp_dir,
ULONGEST  signature 
)
static

Definition at line 11043 of file dwarf2read.c.

References lookup_dwo_cutu().

Referenced by lookup_dwo_unit().

static struct dwo_unit* lookup_dwo_cutu ( struct dwarf2_per_cu_data this_unit,
const char *  dwo_name,
const char *  comp_dir,
ULONGEST  signature,
int  is_debug_types 
)
static
static void** lookup_dwo_file_slot ( const char *  dwo_name,
const char *  comp_dir 
)
static
static struct signatured_type* lookup_dwo_signatured_type ( struct dwarf2_cu cu,
ULONGEST  sig 
)
static
static struct dwo_unit * lookup_dwo_type_unit ( struct signatured_type this_tu,
const char *  dwo_name,
const char *  comp_dir 
)
static

Definition at line 11054 of file dwarf2read.c.

References lookup_dwo_cutu(), signatured_type::per_cu, and signatured_type::signature.

Referenced by lookup_dwo_unit().

static struct dwo_unit* lookup_dwo_unit ( struct dwarf2_per_cu_data this_cu,
struct die_info comp_unit_die 
)
static
static struct dwo_unit * lookup_dwo_unit_in_dwp ( struct dwp_file dwp_file,
const char *  comp_dir,
ULONGEST  signature,
int  is_debug_types 
)
static
static struct signatured_type* lookup_dwp_signatured_type ( struct dwarf2_cu cu,
ULONGEST  sig 
)
static
static struct signatured_type* lookup_signatured_type ( struct dwarf2_cu cu,
ULONGEST  sig 
)
static
static struct macro_source_file* macro_start_file ( int  file,
int  line,
struct macro_source_file current_file,
struct line_header lh 
)
static
static hashval_t mapped_index_string_hash ( int  index_version,
const void *  p 
)
static

Definition at line 2946 of file dwarf2read.c.

Referenced by find_slot(), find_slot_in_mapped_hash(), and hash_strtab_entry().

static void mark_common_block_symbol_computed ( struct symbol sym,
struct die_info common_die,
struct attribute common_loc,
struct attribute member_loc,
struct dwarf2_cu cu 
)
static
static int maybe_queue_comp_unit ( struct dwarf2_cu dependent_cu,
struct dwarf2_per_cu_data per_cu,
enum language  pretend_language 
)
static
static const char * namespace_name ( struct die_info die,
int is_anonymous,
struct dwarf2_cu cu 
)
static
static int need_gnat_info ( struct dwarf2_cu cu)
static

Definition at line 18844 of file dwarf2read.c.

Referenced by set_die_type().

static struct symbol * new_symbol ( struct die_info die,
struct type type,
struct dwarf2_cu cu 
)
static
static struct symbol * new_symbol_full ( struct die_info die,
struct type type,
struct dwarf2_cu cu,
struct symbol space 
)
static

Definition at line 18254 of file dwarf2read.c.

References _, add_symbol_to_list(), allocate_symbol(), ANOFFSET, attr_value_as_address(), objfile_type::builtin_core_addr, COMMON_BLOCK_DOMAIN, complaint(), context_stack_depth, cp_scan_for_anonymous_namespaces(), die_is_declaration(), die_type(), DW_UNSND, dwarf2_attr(), dwarf2_const_value(), dwarf2_full_name(), dwarf2_name(), dwarf2_physname(), dwarf_tag_name(), line_header::file_names, file_symbols, gdb_assert, gdbarch_adjust_dwarf2_addr(), get_objfile_arch(), symbol::ginfo, global_symbols, symbol::hash_next, LABEL_DOMAIN, dwarf2_cu::language, language_ada, language_cplus, language_fortran, language_java, dwarf2_cu::line_header, dwarf2_cu::list_in_scope, LOC_BLOCK, LOC_COMMON_BLOCK, LOC_LABEL, LOC_OPTIMIZED_OUT, LOC_STATIC, LOC_TYPEDEF, LOC_UNRESOLVED, MODULE_DOMAIN, name, objfile_type::nodebug_data_symbol, line_header::num_file_names, dwarf2_cu::objfile, objfile::objfile_obstack, objfile_type(), OBJSTAT, die_info::parent, dwarf2_cu::producer, SECT_OFF_TEXT, objfile::section_offsets, startswith(), STRUCT_DOMAIN, SYMBOL_ACLASS_INDEX, SYMBOL_CLASS, SYMBOL_DOMAIN, symbol_get_demangled_name(), SYMBOL_INLINED, SYMBOL_IS_ARGUMENT, SYMBOL_LINE, SYMBOL_SEARCH_NAME, symbol_set_demangled_name(), SYMBOL_SET_LANGUAGE, SYMBOL_SET_NAMES, symbol_set_symtab(), SYMBOL_TYPE, SYMBOL_VALUE_ADDRESS, symfile_complaints, file_entry::symtab, die_info::tag, objfile::template_symbols, type, TYPE_CODE, TYPE_CODE_VOID, TYPE_NAME, var_decode_location(), and VAR_DOMAIN.

Referenced by new_symbol(), and read_func_scope().

static void noop_record_line ( struct subfile subfile,
int  line,
CORE_ADDR  pc 
)
static

Definition at line 17527 of file dwarf2read.c.

Referenced by check_line_address().

static int offset_in_cu_p ( const struct comp_unit_head cu_header,
sect_offset  offset 
)
inlinestatic
static int offset_type_compare ( const void *  ap,
const void *  bp 
)
static

Definition at line 22714 of file dwarf2read.c.

Referenced by uniquify_cu_indices().

static struct dwo_file* open_and_init_dwo_file ( struct dwarf2_per_cu_data per_cu,
const char *  dwo_name,
const char *  comp_dir 
)
static
static struct dwp_file* open_and_init_dwp_file ( void  )
static
static bfd* open_dwo_file ( const char *  file_name,
const char *  comp_dir 
)
static

Definition at line 10509 of file dwarf2read.c.

References debug_file_directory, SLASH_STRING, try_open_dwop_file(), and xfree().

Referenced by open_and_init_dwo_file().

static bfd* open_dwp_file ( const char *  file_name)
static

Definition at line 10780 of file dwarf2read.c.

References debug_file_directory, and try_open_dwop_file().

Referenced by open_and_init_dwp_file().

static void parse_macro_definition ( struct macro_source_file file,
int  line,
const char *  body 
)
static
static int partial_die_eq ( const void *  item_lhs,
const void *  item_rhs 
)
static

Definition at line 22412 of file dwarf2read.c.

References partial_die_info::offset, and sect_offset::sect_off.

Referenced by load_partial_dies().

static char* partial_die_full_name ( struct partial_die_info pdi,
struct dwarf2_cu cu 
)
static
static hashval_t partial_die_hash ( const void *  item)
static

Definition at line 22401 of file dwarf2read.c.

References partial_die_info::offset, and sect_offset::sect_off.

Referenced by load_partial_dies().

static const char* partial_die_parent_scope ( struct partial_die_info pdi,
struct dwarf2_cu cu 
)
static
static unsigned int peek_abbrev_code ( bfd *  abfd,
const gdb_byte info_ptr 
)
static
static struct abbrev_info* peek_die_abbrev ( const gdb_byte info_ptr,
unsigned int bytes_read,
struct dwarf2_cu cu 
)
static
static const struct comp_unit_head* per_cu_header_read_in ( struct comp_unit_head cu_headerp,
struct dwarf2_per_cu_data per_cu 
)
static
static int per_cu_offset_and_type_eq ( const void *  item_lhs,
const void *  item_rhs 
)
static
static hashval_t per_cu_offset_and_type_hash ( const void *  item)
static
static void prepare_one_comp_unit ( struct dwarf2_cu cu,
struct die_info comp_unit_die,
enum language  pretend_language 
)
static
static void print_tu_stats ( void  )
static
static void process_cu_includes ( void  )
static
static void process_die ( struct die_info die,
struct dwarf2_cu cu 
)
static
static int process_dwo_file_for_skeletonless_type_units ( void **  slot,
void *  info 
)
static

Definition at line 6376 of file dwarf2read.c.

References process_skeletonless_type_unit(), and dwo_file::tus.

Referenced by process_skeletonless_type_units().

static void process_enumeration_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void process_full_comp_unit ( struct dwarf2_per_cu_data per_cu,
enum language  pretend_language 
)
static
static void process_full_type_unit ( struct dwarf2_per_cu_data per_cu,
enum language  pretend_language 
)
static
static void process_imported_unit_die ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void process_psymtab_comp_unit ( struct dwarf2_per_cu_data this_cu,
int  want_partial_unit,
enum language  pretend_language 
)
static
static void process_psymtab_comp_unit_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  data 
)
static
static void process_queue ( void  )
static
static int process_skeletonless_type_unit ( void **  slot,
void *  info 
)
static
static void process_skeletonless_type_units ( struct objfile objfile)
static
static void process_structure_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static
static int producer_is_gcc_lt_4_3 ( struct dwarf2_cu cu)
static

Definition at line 9022 of file dwarf2read.c.

References check_producer().

Referenced by find_file_and_directory().

static int producer_is_gxx_lt_4_6 ( struct dwarf2_cu cu)
static

Definition at line 12356 of file dwarf2read.c.

References check_producer().

Referenced by dwarf2_default_access_attribute().

static int producer_is_icc ( struct dwarf2_cu cu)
static

Definition at line 13095 of file dwarf2read.c.

References check_producer().

Referenced by read_structure_type().

static int prototyped_function_p ( struct die_info die,
struct dwarf2_cu cu 
)
static
static const char* psymtab_include_file_name ( const struct line_header lh,
int  file_index,
const struct partial_symtab pst,
const char *  comp_dir 
)
static
static void psymtab_to_symtab_1 ( struct partial_symtab pst)
static
static void psymtabs_addrmap_cleanup ( void *  o)
static

Definition at line 6409 of file dwarf2read.c.

References objfile::psymtabs_addrmap.

Referenced by dwarf2_build_psymtabs_hard().

static void queue_and_load_all_dwo_tus ( struct dwarf2_per_cu_data per_cu)
static
static int queue_and_load_dwo_tu ( void **  slot,
void *  info 
)
static
static void queue_comp_unit ( struct dwarf2_per_cu_data per_cu,
enum language  pretend_language 
)
static
static void quirk_gcc_member_function_pointer ( struct type type,
struct objfile objfile 
)
static
static unsigned int read_1_byte ( bfd *  abfd,
const gdb_byte buf 
)
static
static int read_1_signed_byte ( bfd *  abfd,
const gdb_byte buf 
)
static

Definition at line 16431 of file dwarf2read.c.

Referenced by decode_locdesc(), and dwarf_decode_line_header().

static unsigned int read_2_bytes ( bfd *  abfd,
const gdb_byte buf 
)
static
static int read_2_signed_bytes ( bfd *  abfd,
const gdb_byte buf 
)
static

Definition at line 16443 of file dwarf2read.c.

Referenced by decode_locdesc().

static unsigned int read_4_bytes ( bfd *  abfd,
const gdb_byte buf 
)
static
static int read_4_signed_bytes ( bfd *  abfd,
const gdb_byte buf 
)
static

Definition at line 16455 of file dwarf2read.c.

Referenced by decode_locdesc().

static ULONGEST read_8_bytes ( bfd *  abfd,
const gdb_byte buf 
)
static
static sect_offset read_abbrev_offset ( struct dwarf2_section_info section,
sect_offset  offset 
)
static
static CORE_ADDR read_addr_index ( struct dwarf2_cu cu,
unsigned int  addr_index 
)
static
static CORE_ADDR read_addr_index_1 ( unsigned int  addr_index,
ULONGEST  addr_base,
int  addr_size 
)
static
static CORE_ADDR read_addr_index_from_leb128 ( struct dwarf2_cu cu,
const gdb_byte info_ptr,
unsigned int bytes_read 
)
static
static CORE_ADDR read_address ( bfd *  abfd,
const gdb_byte ptr,
struct dwarf2_cu cu,
unsigned int bytes_read 
)
static
static const gdb_byte * read_and_check_comp_unit_head ( struct comp_unit_head header,
struct dwarf2_section_info section,
struct dwarf2_section_info abbrev_section,
const gdb_byte info_ptr,
int  is_debug_types_section 
)
static
static const gdb_byte* read_and_check_type_unit_head ( struct comp_unit_head header,
struct dwarf2_section_info section,
struct dwarf2_section_info abbrev_section,
const gdb_byte info_ptr,
ULONGEST signature,
cu_offset type_offset_in_tu 
)
static
static enum dwarf_array_dim_ordering read_array_order ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_array_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static const gdb_byte * read_attribute ( const struct die_reader_specs reader,
struct attribute attr,
struct attr_abbrev abbrev,
const gdb_byte info_ptr 
)
static
static const gdb_byte* read_attribute_value ( const struct die_reader_specs reader,
struct attribute attr,
unsigned  form,
const gdb_byte info_ptr 
)
static
static struct type* read_base_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void read_call_site_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static

Definition at line 11550 of file dwarf2read.c.

References _, ANOFFSET, attr_form_is_block(), attr_form_is_ref(), attr_value_as_address(), CALL_SITE_PARAMETER_DWARF_REG, CALL_SITE_PARAMETER_FB_OFFSET, CALL_SITE_PARAMETER_PARAM_OFFSET, die_info::child, complaint(), core_addr_eq(), core_addr_hash(), cu_offset::cu_off, dwarf2_locexpr_baton::data, call_site_parameter::data_value, call_site_parameter::data_value_size, die_is_declaration(), DW_BLOCK, DW_STRING, dwarf2_attr(), dwarf2_flag_true_p(), dwarf2_get_pc_bounds(), dwarf2_get_ref_die_offset(), dwarf2_physname(), dwarf_block_to_dwarf_reg(), dwarf_block_to_sp_offset(), call_site_parameter_u::dwarf_reg, call_site_parameter_u::fb_offset, follow_die_ref(), gdb_assert, gdbarch_adjust_dwarf2_addr(), get_die_type(), get_objfile_arch(), hashtab_obstack_allocate(), dwarf2_cu::header, call_site_parameter::kind, dwarf2_cu::objfile, objfile_name(), objfile::objfile_obstack, offset, comp_unit_head::offset, die_info::offset, offset_in_cu_p(), paddress(), call_site_parameter_u::param_offset, call_site::parameter, call_site::parameter_count, die_info::parent, call_site::pc, dwarf2_locexpr_baton::per_cu, dwarf2_cu::per_cu, call_site::per_cu, sect_offset::sect_off, SECT_OFF_TEXT, objfile::section_offsets, SET_FIELD_DWARF_BLOCK, SET_FIELD_PHYSADDR, SET_FIELD_PHYSNAME, sibling_die(), dwarf2_locexpr_baton::size, size, symfile_complaints, die_info::tag, call_site::tail_call_next, call_site::target, TYPE_CODE, TYPE_CODE_FUNC, TYPE_TAIL_CALL_LIST, call_site_parameter::u, call_site_parameter::value, and call_site_parameter::value_size.

Referenced by process_die().

static LONGEST read_checked_initial_length_and_offset ( bfd *  abfd,
const gdb_byte buf,
const struct comp_unit_head cu_header,
unsigned int bytes_read,
unsigned int offset_size 
)
static
static void read_common_block ( struct die_info die,
struct dwarf2_cu cu 
)
static
static const gdb_byte* read_comp_unit_head ( struct comp_unit_head cu_header,
const gdb_byte info_ptr,
bfd *  abfd 
)
static
static void read_comp_units_from_section ( struct objfile objfile,
struct dwarf2_section_info section,
unsigned int  is_dwz,
int n_allocated,
int n_comp_units,
struct dwarf2_per_cu_data ***  all_comp_units 
)
static
static int read_cutu_die_from_dwo ( struct dwarf2_per_cu_data this_cu,
struct dwo_unit dwo_unit,
int  abbrev_table_provided,
struct die_info stub_comp_unit_die,
const char *  stub_comp_dir,
struct die_reader_specs result_reader,
const gdb_byte **  result_info_ptr,
struct die_info **  result_comp_unit_die,
int result_has_children 
)
static
static struct die_info* read_die_and_children ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
const gdb_byte **  new_info_ptr,
struct die_info parent 
)
static
static struct die_info * read_die_and_siblings ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
const gdb_byte **  new_info_ptr,
struct die_info parent 
)
static
static struct die_info * read_die_and_siblings_1 ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
const gdb_byte **  new_info_ptr,
struct die_info parent 
)
static

Definition at line 15102 of file dwarf2read.c.

References read_die_and_children(), and die_info::sibling.

Referenced by read_die_and_children(), and read_die_and_siblings().

static const char * read_direct_string ( bfd *  abfd,
const gdb_byte buf,
unsigned int bytes_read_ptr 
)
static
static struct type* read_enumeration_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void read_file_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static
static const gdb_byte * read_full_die ( const struct die_reader_specs reader,
struct die_info **  diep,
const gdb_byte info_ptr,
int has_children 
)
static
static const gdb_byte * read_full_die_1 ( const struct die_reader_specs reader,
struct die_info **  diep,
const gdb_byte info_ptr,
int has_children,
int  num_extra_attrs 
)
static
static void read_func_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void read_import_statement ( struct die_info die,
struct dwarf2_cu cu 
)
static
static int read_index_from_section ( struct objfile objfile,
const char *  filename,
int  deprecated_ok,
struct dwarf2_section_info section,
struct mapped_index map,
const gdb_byte **  cu_list,
offset_type cu_list_elements,
const gdb_byte **  types_list,
offset_type types_list_elements 
)
static
static const char * read_indirect_string ( bfd *  abfd,
const gdb_byte buf,
const struct comp_unit_head cu_header,
unsigned int bytes_read_ptr 
)
static

Definition at line 16714 of file dwarf2read.c.

References read_indirect_string_at_offset(), and read_offset().

Referenced by read_attribute_value().

static const char* read_indirect_string_at_offset ( bfd *  abfd,
LONGEST  str_offset 
)
static
static const char * read_indirect_string_from_dwz ( struct dwz_file dwz,
LONGEST  str_offset 
)
static
static LONGEST read_initial_length ( bfd *  abfd,
const gdb_byte buf,
unsigned int bytes_read 
)
static
static void read_lexical_block_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void read_module ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * read_module_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static const gdb_byte * read_n_bytes ( bfd *  abfd,
const gdb_byte buf,
unsigned int  size 
)
static

Definition at line 16646 of file dwarf2read.c.

References gdb_assert, and HOST_CHAR_BIT.

Referenced by read_attribute_value().

static void read_namespace ( struct die_info die,
struct dwarf2_cu cu 
)
static
static int read_namespace_alias ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_namespace_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static LONGEST read_offset ( bfd *  abfd,
const gdb_byte buf,
const struct comp_unit_head cu_header,
unsigned int bytes_read 
)
static
static LONGEST read_offset_1 ( bfd *  abfd,
const gdb_byte buf,
unsigned int  offset_size 
)
static
static const gdb_byte * read_partial_die ( const struct die_reader_specs reader,
struct partial_die_info part_die,
struct abbrev_info abbrev,
unsigned int  abbrev_len,
const gdb_byte info_ptr 
)
static

Definition at line 15753 of file dwarf2read.c.

References _, attr_form_is_block(), attr_form_is_constant(), attr_form_is_section_offset(), attr_value_as_address(), abbrev_info::attrs, die_reader_specs::buffer, die_reader_specs::buffer_end, complaint(), die_reader_specs::cu, partial_die_info::d, die_reader_specs::die_section, DW_BLOCK, DW_STRING, DW_UNSND, dwarf2_canonicalize_name(), dwarf2_complex_location_expr_complaint(), dwarf2_get_ref_die_offset(), dwarf2_invalid_attrib_class_complaint(), dwarf2_section_buffer_overflow_complaint(), attribute::form, get_objfile_arch(), partial_die_info::has_byte_size, partial_die_info::has_children, abbrev_info::has_children, partial_die_info::has_const_value, partial_die_info::has_pc_info, partial_die_info::has_specification, partial_die_info::has_type, dwarf2_cu::header, partial_die_info::highpc, partial_die_info::is_declaration, dwarf2_per_cu_data::is_dwz, partial_die_info::is_dwz, partial_die_info::is_external, dwarf2_cu::language, language_ada, language_fortran, partial_die_info::linkage_name, partial_die_info::locdesc, partial_die_info::lowpc, partial_die_info::may_be_inlined, partial_die_info::name, attribute::name, abbrev_info::num_attrs, dwarf2_cu::objfile, objfile_name(), partial_die_info::offset, paddress(), objfile::per_bfd, dwarf2_cu::per_cu, read_attribute(), sect_offset::sect_off, set_objfile_main_name(), partial_die_info::sibling, partial_die_info::spec_is_dwz, partial_die_info::spec_offset, objfile_per_bfd_storage::storage_obstack, symfile_complaints, partial_die_info::tag, abbrev_info::tag, and comp_unit_head::version.

Referenced by load_partial_dies().

static struct type* read_set_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void read_signatured_type ( struct signatured_type sig_type)
static
static void read_signatured_type_reader ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct die_info comp_unit_die,
int  has_children,
void *  data 
)
static
static LONGEST read_signed_leb128 ( bfd *  abfd,
const gdb_byte buf,
unsigned int bytes_read_ptr 
)
static

Definition at line 16753 of file dwarf2read.c.

Referenced by decode_locdesc(), dwarf_decode_lines_1(), and read_attribute_value().

static const char * read_str_index ( const struct die_reader_specs reader,
ULONGEST  str_index 
)
static
static struct type* read_structure_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_subrange_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_subroutine_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_tag_atomic_type ( struct die_info die,
struct dwarf2_cu cu 
)
static

Definition at line 14410 of file dwarf2read.c.

References die_type(), get_die_type(), make_atomic_type(), and set_die_type().

Referenced by read_type_die_1().

static struct type* read_tag_const_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_tag_pointer_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_tag_ptr_to_member_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_tag_reference_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_tag_restrict_type ( struct die_info die,
struct dwarf2_cu cu 
)
static

Definition at line 14392 of file dwarf2read.c.

References die_type(), get_die_type(), make_restrict_type(), and set_die_type().

Referenced by read_type_die_1().

static struct type* read_tag_string_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_tag_volatile_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * read_type_die ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * read_type_die_1 ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void read_type_unit_scope ( struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type* read_typedef ( struct die_info die,
struct dwarf2_cu cu 
)
static
static ULONGEST read_unsigned_leb128 ( bfd *  abfd,
const gdb_byte buf,
unsigned int bytes_read_ptr 
)
static
static struct type* read_unspecified_type ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void recursively_compute_inclusions ( VEC(compunit_symtab_ptr)**  result,
htab_t  all_children,
htab_t  all_type_symtabs,
struct dwarf2_per_cu_data per_cu,
struct compunit_symtab immediate_parent 
)
static
static struct compunit_symtab* recursively_find_pc_sect_compunit_symtab ( struct compunit_symtab cust,
CORE_ADDR  pc 
)
static
static void recursively_write_psymbols ( struct objfile objfile,
struct partial_symtab psymtab,
struct mapped_symtab symtab,
htab_t  psyms_seen,
offset_type  cu_index 
)
static
static void reset_die_in_process ( void *  arg)
static

Definition at line 8236 of file dwarf2read.c.

References die_info::in_process.

Referenced by process_die().

static void save_gdb_index_command ( char *  arg,
int  from_tty 
)
static
static void scan_partial_symbols ( struct partial_die_info first_die,
CORE_ADDR lowpc,
CORE_ADDR highpc,
int  set_addrmap,
struct dwarf2_cu cu 
)
static
static int section_is_p ( const char *  section_name,
const struct dwarf2_section_names names 
)
static
static void set_cu_language ( unsigned int  lang,
struct dwarf2_cu cu 
)
static
static void set_descriptive_type ( struct type type,
struct die_info die,
struct dwarf2_cu cu 
)
static
static struct type * set_die_type ( struct die_info die,
struct type type,
struct dwarf2_cu cu 
)
static
static void set_dwarf_cmd ( char *  args,
int  from_tty 
)
static

Definition at line 22424 of file dwarf2read.c.

References all_commands, gdb_stdout, and help_list().

Referenced by _initialize_dwarf2_read().

static void set_partial_user ( struct objfile objfile)
static
static void setup_type_unit_groups ( struct die_info die,
struct dwarf2_cu cu 
)
static
static void show_check_physname ( struct ui_file file,
int  from_tty,
struct cmd_list_element c,
const char *  value 
)
static

Definition at line 23384 of file dwarf2read.c.

References _, and fprintf_filtered().

Referenced by _initialize_dwarf2_read().

static void show_dwarf_always_disassemble ( struct ui_file file,
int  from_tty,
struct cmd_list_element c,
const char *  value 
)
static

Definition at line 23374 of file dwarf2read.c.

References _, and fprintf_filtered().

Referenced by _initialize_dwarf2_read().

static void show_dwarf_cmd ( char *  args,
int  from_tty 
)
static

Definition at line 22431 of file dwarf2read.c.

References cmd_show_list().

Referenced by _initialize_dwarf2_read().

static void show_dwarf_max_cache_age ( struct ui_file file,
int  from_tty,
struct cmd_list_element c,
const char *  value 
)
static

Definition at line 1381 of file dwarf2read.c.

References _, and fprintf_filtered().

Referenced by _initialize_dwarf2_read().

static struct die_info * sibling_die ( struct die_info die)
static
static const gdb_byte* skip_children ( const struct die_reader_specs reader,
const gdb_byte info_ptr 
)
static

Definition at line 7235 of file dwarf2read.c.

References die_reader_specs::cu, peek_die_abbrev(), and skip_one_die().

Referenced by locate_pdi_sibling(), and skip_one_die().

static const gdb_byte* skip_form_bytes ( bfd *  abfd,
const gdb_byte bytes,
const gdb_byte buffer_end,
enum dwarf_form  form,
unsigned int  offset_size,
struct dwarf2_section_info section 
)
static
static const gdb_byte * skip_one_die ( const struct die_reader_specs reader,
const gdb_byte info_ptr,
struct abbrev_info abbrev 
)
static
static const gdb_byte* skip_unknown_opcode ( unsigned int  opcode,
const gdb_byte **  opcode_definitions,
const gdb_byte mac_ptr,
const gdb_byte mac_end,
bfd *  abfd,
unsigned int  offset_size,
struct dwarf2_section_info section 
)
static
static int sort_tu_by_abbrev_offset ( const void *  ap,
const void *  bp 
)
static

Definition at line 6149 of file dwarf2read.c.

References tu_abbrev_offset::abbrev_offset, and sect_offset::sect_off.

Referenced by build_type_psymtabs_1().

static void store_in_ref_table ( struct die_info die,
struct dwarf2_cu cu 
)
static

Definition at line 19832 of file dwarf2read.c.

References dwarf2_cu::die_hash, die_info::offset, and sect_offset::sect_off.

Referenced by read_die_and_children().

static gdb_index_symbol_kind symbol_kind ( struct partial_symbol psym)
static
static bfd* try_open_dwop_file ( const char *  file_name,
int  is_dwp,
int  search_cwd 
)
static
static char * typename_concat ( struct obstack *  obs,
const char *  prefix,
const char *  suffix,
int  physname,
struct dwarf2_cu cu 
)
static
static void uniquify_cu_indices ( struct mapped_symtab symtab)
static
static void unlink_if_set ( void *  p)
static

Definition at line 23059 of file dwarf2read.c.

Referenced by write_psymtabs_to_index().

static int unsigned_int_compar ( const void *  ap,
const void *  bp 
)
static

Definition at line 11162 of file dwarf2read.c.

Referenced by inherit_abstract_dies().

static void update_enumeration_type_from_children ( struct die_info die,
struct type type,
struct dwarf2_cu cu 
)
static
static void var_decode_location ( struct attribute attr,
struct symbol sym,
struct dwarf2_cu cu 
)
static
static void write_address_map ( struct objfile objfile,
struct obstack *  obstack,
htab_t  cu_index_htab 
)
static
static const gdb_byte* write_constant_as_bytes ( struct obstack *  obstack,
enum bfd_endian  byte_order,
struct type type,
ULONGEST  value,
LONGEST len 
)
static

Definition at line 20064 of file dwarf2read.c.

References store_unsigned_integer(), and TYPE_LENGTH.

Referenced by dwarf2_fetch_constant_bytes().

static void write_hash_table ( struct mapped_symtab symtab,
struct obstack *  output,
struct obstack *  cpool 
)
static
static void write_obstack ( FILE *  file,
struct obstack *  obstack 
)
static

Definition at line 23048 of file dwarf2read.c.

References _, and error().

Referenced by write_psymtabs_to_index().

static int write_one_signatured_type ( void **  slot,
void *  d 
)
static
static void write_psymbols ( struct mapped_symtab symtab,
htab_t  psyms_seen,
struct partial_symbol **  psymp,
int  count,
offset_type  cu_index,
int  is_static 
)
static
static void write_psymtabs_to_index ( struct objfile objfile,
const char *  dir 
)
static

Variable Documentation

int bits_per_byte = 8
static

Definition at line 1298 of file dwarf2read.c.

Referenced by dwarf2_add_field(), and mips_isa_regsize().

int check_physname = 0
static

Definition at line 91 of file dwarf2read.c.

Referenced by _initialize_dwarf2_read(), and dwarf2_physname().

const struct dwarf2_debug_sections dwarf2_elf_names
static
Initial value:
=
{
{ ".debug_info", ".zdebug_info" },
{ ".debug_abbrev", ".zdebug_abbrev" },
{ ".debug_line", ".zdebug_line" },
{ ".debug_loc", ".zdebug_loc" },
{ ".debug_macinfo", ".zdebug_macinfo" },
{ ".debug_macro", ".zdebug_macro" },
{ ".debug_str", ".zdebug_str" },
{ ".debug_ranges", ".zdebug_ranges" },
{ ".debug_types", ".zdebug_types" },
{ ".debug_addr", ".zdebug_addr" },
{ ".debug_frame", ".zdebug_frame" },
{ ".eh_frame", NULL },
{ ".gdb_index", ".zgdb_index" },
23
}

Definition at line 328 of file dwarf2read.c.

Referenced by dwarf2_locate_sections().

const struct quick_symbol_functions dwarf2_gdb_index_functions
Initial value:
=
{
}
static void dw2_map_matching_symbols(struct objfile *objfile, const char *name, domain_enum domain, int global, int(*callback)(struct block *, struct symbol *, void *), void *data, symbol_compare_ftype *match, symbol_compare_ftype *ordered_compare)
Definition: dwarf2read.c:3828
static void dw2_map_symbol_filenames(struct objfile *objfile, symbol_filename_ftype *fun, void *data, int need_fullname)
Definition: dwarf2read.c:4099
static struct symtab * dw2_find_last_source_symtab(struct objfile *objfile)
Definition: dwarf2read.c:3365
static void dw2_expand_symtabs_matching(struct objfile *objfile, expand_symtabs_file_matcher_ftype *file_matcher, expand_symtabs_symbol_matcher_ftype *symbol_matcher, expand_symtabs_exp_notify_ftype *expansion_notify, enum search_domain kind, void *data)
Definition: dwarf2read.c:3843
static int dw2_map_symtabs_matching_filename(struct objfile *objfile, const char *name, const char *real_path, int(*callback)(struct symtab *, void *), void *data)
Definition: dwarf2read.c:3435
static void dw2_expand_symtabs_with_fullname(struct objfile *objfile, const char *fullname)
Definition: dwarf2read.c:3788
static void dw2_expand_all_symtabs(struct objfile *objfile)
Definition: dwarf2read.c:3772
static void dw2_relocate(struct objfile *objfile, const struct section_offsets *new_offsets, const struct section_offsets *delta)
Definition: dwarf2read.c:3739
static struct compunit_symtab * dw2_lookup_symbol(struct objfile *objfile, int block_index, const char *name, domain_enum domain)
Definition: dwarf2read.c:3651
static void dw2_forget_cached_source_info(struct objfile *objfile)
Definition: dwarf2read.c:3400
static struct compunit_symtab * dw2_find_pc_sect_compunit_symtab(struct objfile *objfile, struct bound_minimal_symbol msymbol, CORE_ADDR pc, struct obj_section *section, int warn_if_readin)
Definition: dwarf2read.c:4069
static void dw2_expand_symtabs_for_function(struct objfile *objfile, const char *func_name)
Definition: dwarf2read.c:3747
static void dw2_dump(struct objfile *objfile)
Definition: dwarf2read.c:3723
static int dw2_has_symbols(struct objfile *objfile)
Definition: dwarf2read.c:4166
static void dw2_print_stats(struct objfile *objfile)
Definition: dwarf2read.c:3699

Definition at line 4171 of file dwarf2read.c.

int dwarf2_locexpr_block_index
static

Definition at line 102 of file dwarf2read.c.

Referenced by _initialize_dwarf2_read(), and dwarf2_symbol_mark_computed().

int dwarf2_locexpr_index
static
int dwarf2_loclist_block_index
static

Definition at line 103 of file dwarf2read.c.

Referenced by _initialize_dwarf2_read(), and dwarf2_symbol_mark_computed().

int dwarf2_loclist_index
static

Definition at line 101 of file dwarf2read.c.

Referenced by _initialize_dwarf2_read(), and dwarf2_symbol_mark_computed().

const struct objfile_data* dwarf2_objfile_data_key
static

Definition at line 321 of file dwarf2read.c.

struct dwarf2_queue_item* dwarf2_queue
static

Definition at line 1372 of file dwarf2read.c.

Referenced by dwarf2_release_queue().

struct dwarf2_queue_item * dwarf2_queue_tail
static

Definition at line 1372 of file dwarf2read.c.

int dwarf_always_disassemble

Definition at line 23371 of file dwarf2read.c.

Referenced by locexpr_describe_location_1().

unsigned int dwarf_die_debug = 0
static
unsigned int dwarf_line_debug = 0
static
int dwarf_max_cache_age = 5
static

Definition at line 1379 of file dwarf2read.c.

Referenced by _initialize_dwarf2_read(), and age_cached_comp_units().

unsigned int dwarf_read_debug = 0
static
Initial value:
=
{
{ ".debug_abbrev.dwo", ".zdebug_abbrev.dwo" },
{ ".debug_info.dwo", ".zdebug_info.dwo" },
{ ".debug_line.dwo", ".zdebug_line.dwo" },
{ ".debug_loc.dwo", ".zdebug_loc.dwo" },
{ ".debug_macinfo.dwo", ".zdebug_macinfo.dwo" },
{ ".debug_macro.dwo", ".zdebug_macro.dwo" },
{ ".debug_str.dwo", ".zdebug_str.dwo" },
{ ".debug_str_offsets.dwo", ".zdebug_str_offsets.dwo" },
{ ".debug_types.dwo", ".zdebug_types.dwo" },
{ ".debug_cu_index", ".zdebug_cu_index" },
{ ".debug_tu_index", ".zdebug_tu_index" },
}

Referenced by dwarf2_locate_common_dwp_sections(), dwarf2_locate_dwo_sections(), dwarf2_locate_v2_dwp_sections(), and locate_v1_virtual_dwo_sections().

struct cmd_list_element* set_dwarf_cmdlist
static

Definition at line 22420 of file dwarf2read.c.

struct cmd_list_element* show_dwarf_cmdlist
static

Definition at line 22421 of file dwarf2read.c.

int use_deprecated_index_sections = 0
static

Definition at line 94 of file dwarf2read.c.

Referenced by _initialize_dwarf2_read(), and dwarf2_read_index().