X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2Fdwarf2read.h;h=8845e99d6bff5b5b64294afb1e94c194b22961de;hb=d55e5aa6b29906346c51ad00e6a9b112590aa294;hp=8e6c41dc09ef1f63645c538da2666ecb3f628a69;hpb=b2bdb8cf395f491319264cda42e41538f55a86d9;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/dwarf2read.h b/gdb/dwarf2read.h index 8e6c41dc09..8845e99d6b 100644 --- a/gdb/dwarf2read.h +++ b/gdb/dwarf2read.h @@ -1,6 +1,6 @@ /* DWARF 2 debugging format support for GDB. - Copyright (C) 1994-2018 Free Software Foundation, Inc. + Copyright (C) 1994-2019 Free Software Foundation, Inc. This file is part of GDB. @@ -20,9 +20,17 @@ #ifndef DWARF2READ_H #define DWARF2READ_H +#include + +/* Local non-gdb includes. */ +#include "dwarf-index-cache.h" #include "filename-seen-cache.h" #include "gdb_obstack.h" +/* Hold 'maintenance (set|show) dwarf' commands. */ +extern struct cmd_list_element *set_dwarf_cmdlist; +extern struct cmd_list_element *show_dwarf_cmdlist; + typedef struct dwarf2_per_cu_data *dwarf2_per_cu_ptr; DEF_VEC_P (dwarf2_per_cu_ptr); @@ -90,6 +98,8 @@ struct dwarf2_debug_sections; struct mapped_index; struct mapped_debug_names; struct signatured_type; +struct die_info; +typedef struct die_info *die_info_ptr; /* Collection of data recorded per objfile. This hangs off of dwarf2_objfile_data_key. */ @@ -194,11 +204,11 @@ public: bool dwp_checked = false; /* The DWP file if there is one, or NULL. */ - struct dwp_file *dwp_file = NULL; + std::unique_ptr dwp_file; /* The shared '.dwz' file, if one exists. This is used when the original data was compressed using 'dwz -m'. */ - struct dwz_file *dwz_file = NULL; + std::unique_ptr dwz_file; /* A flag indicating whether this objfile has a section loaded at a VMA of 0. */ @@ -209,7 +219,7 @@ public: bool using_index = false; /* The mapped index, or NULL if .gdb_index is missing or not being used. */ - mapped_index *index_table = NULL; + std::unique_ptr index_table; /* The mapped index, or NULL if .debug_names is missing or not being used. */ std::unique_ptr debug_names_table; @@ -233,7 +243,7 @@ public: htab_t die_type_hash {}; /* The CUs we recently read. */ - VEC (dwarf2_per_cu_ptr) *just_read_cus = NULL; + std::vector just_read_cus; /* Table containing line_header indexed by offset and offset_in_dwz. */ htab_t line_header_hash {}; @@ -241,6 +251,15 @@ public: /* Table containing all filenames. This is an optional because the table is lazily constructed on first access. */ gdb::optional filenames_cache; + + /* If we loaded the index from an external file, this contains the + resources associated to the open file, memory mapping, etc. */ + std::unique_ptr index_cache_res; + + /* Mapping from abstract origin DIE to concrete DIEs that reference it as + DW_AT_abstract_origin. */ + std::unordered_map> + abstract_to_concrete; }; /* Get the dwarf2_per_objfile associated to OBJFILE. */