(please add anyone who has a vested interest in Split DWARF in general and dwp in particular)
tl;dr: How should DWARFv4 and DWARFv5 coexist in a DWP file: 1) Not at all (invalid/unsupported) 2) Single index table where the section indexes are subjective (look at the version of the referenced CU/TU to decide what a column number means (eg: 8 is DW_SECT_MACRO in v4, DW_SECT_RNGLISTS in v5) 3) Emit multiple indexes (cu_index and tu_index each would contain two indexes) - a v4 (well, index version 2) and a v5 (index version 5) index. Longer discussion: So I'm working on some (perhaps admittedly a bit hackish at this stage) support for DWARFv5 in binutils' dwp tool. So far I've adde support for parsing the DWARFv5 header and for correctly handling str_offsets in v5 where a header is present. (& appropriately only skipping the header for a v5 contribution (which means having to look at the compile unit before parsing the corresponding str_offsets contribution)) But looking at supporting rnglists and loclists it gets a bit fuzzier when it comes to the cu_index - debug_loc and debug_loclists share the same DW_SECT numbering (5) in the pre-standard format ( https://gcc.gnu.org/wiki/DebugFissionDWP ) and in DWARFv5 ( http://dwarfstd.org/doc/DWARF5.pdf - Table 7.1), so that's sort of fungible. rnglists is the trickier one - it doesn't exist in the pre-standard form doesn't have this field (it has DW_SECT_MACINFO at 7 and DW_SECT_MACRO at 8), the standard version does (DW_SECT_MACRO at 7, DW_SECT_RNGLISTS at 8). So... that leaves me with the question at the top: Unsupported, contextually interpreted (read the CU/TU to find the DWARF version, use that to decide which section name a column index refers to), two indexes (pre-standard and v5)?
_______________________________________________ Dwarf-Discuss mailing list Dwarf-Discuss@lists.dwarfstd.org http://lists.dwarfstd.org/listinfo.cgi/dwarf-discuss-dwarfstd.org