summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorCaroline Tice <cmtice@google.com>2020-09-08 09:14:29 -0700
committerCaroline Tice <cmtice@google.com>2020-09-09 14:05:04 -0700
commitde8421dd8a040619eca72be1ce1cb4b2eeafade9 (patch)
tree0c2c9515fa952c55f67fee5c9b17d1970bf13540 /include
parent25ef215abb1aa701db7ab173b9f2ac653cecf634 (diff)
Add codes for DWARF v5 .dwp sections to dwarf2.h.
(Note: This patch has already been accepted/committed in binutils/GDB. This will bring the same change into the GCC tree.) For DWARF v5 Dwarf Package Files (.dwp files), the section identifier encodings have changed. This patch updates dwarf2.h to contain the new encodings. The table below shows the old & new encodings: [ref http://dwarfstd.org/doc/DWARF5.pdf, section 7.3.5. ] Val DW4 section DW4 section id DW5 section DW5 section id --- ----------------- -------------- ----------------- -------------- 1 .debug_info.dwo DW_SECT_INFO .debug_info.dwo DW_SECT_INFO 2 .debug_types.dwo DW_SECT_TYPES -- reserved 3 .debug_abbrev.dwo DW_SECT_ABBREV .debug_abbrev.dwo DW_SECT_ABBREV 4 .debug_line.dwo DW_SECT_LINE .debug_line.dwo DW_SECT_LINE 5 .debug_loc.dwo DW_SECT_LOC .debug_loclists.dwo DW_SECT_LOCLISTS 6 .debug_str_offsets.dwo .debug_str_offsets.dwo DW_SECT_STR_OFFSETS DW_SECT_STR_OFFSETS 7 .debug_macinfo.dwo DW_SECT_MACINFO .debug_macro.dwo DW_SECT_MACRO 8 .debug_macro.dwo DW_SECT_MACRO .debug_rnglists.dwo DW_SECT_RNGLISTS 2020-09-09 Caroline Tice <cmtice@google.com> include/ * dwarf2.h (enum dwarf_sect_v5): A new enum section for the sections in a DWARF 5 DWP file (DWP version 5).
Diffstat (limited to 'include')
-rw-r--r--include/dwarf2.h41
1 files changed, 29 insertions, 12 deletions
diff --git a/include/dwarf2.h b/include/dwarf2.h
index 0b6facfd4cf..34273e84a5a 100644
--- a/include/dwarf2.h
+++ b/include/dwarf2.h
@@ -489,19 +489,36 @@ enum dwarf_unit_type
#define DW_EH_PE_indirect 0x80
/* Codes for the debug sections in a dwarf package (.dwp) file.
- Extensions for Fission. See http://gcc.gnu.org/wiki/DebugFissionDWP. */
+ (From the pre-standard formats Extensions for Fission.
+ See http://gcc.gnu.org/wiki/DebugFissionDWP). */
enum dwarf_sect
- {
- DW_SECT_INFO = 1,
- DW_SECT_TYPES = 2,
- DW_SECT_ABBREV = 3,
- DW_SECT_LINE = 4,
- DW_SECT_LOC = 5,
- DW_SECT_STR_OFFSETS = 6,
- DW_SECT_MACINFO = 7,
- DW_SECT_MACRO = 8,
- DW_SECT_MAX = 8
- };
+{
+ DW_SECT_INFO = 1,
+ DW_SECT_TYPES = 2,
+ DW_SECT_ABBREV = 3,
+ DW_SECT_LINE = 4,
+ DW_SECT_LOC = 5,
+ DW_SECT_STR_OFFSETS = 6,
+ DW_SECT_MACINFO = 7,
+ DW_SECT_MACRO = 8,
+ DW_SECT_MAX = 8
+};
+
+/* Codes for the debug sections in a dwarf package (.dwp) file.
+ (From the official DWARF v5 spec.
+ See http://dwarfstd.org/doc/DWARF5.pdf, section 7.3.5). */
+enum dwarf_sect_v5
+{
+ DW_SECT_INFO_V5 = 1,
+ DW_SECT_RESERVED_V5 = 2,
+ DW_SECT_ABBREV_V5 = 3,
+ DW_SECT_LINE_V5 = 4,
+ DW_SECT_LOCLISTS_V5 = 5,
+ DW_SECT_STR_OFFSETS_V5 = 6,
+ DW_SECT_MACRO_V5 = 7,
+ DW_SECT_RNGLISTS_V5 = 8,
+ DW_SECT_MAX_V5 = 8
+};
#ifdef __cplusplus
extern "C" {