[PATCH] libdw: Parse new DWARF5 units and CU DIEs.

2018-01-30 Thread Mark Wielaard
Parse DWARF5 units, add the unit_type to the Dwarf_CU and generalize some code calculating the header length and getting at the first DIE of a unit. Unit headers can have different sizes depending on the unit type. Signed-off-by: Mark Wielaard --- libdw/ChangeLog| 36

[PATCH] libdw: Add new dwarf_get_units function to iterate over all units.

2018-01-30 Thread Mark Wielaard
The dwarf_nextcu and dwarf_next_unit functions provide information to construct the offset to construct the associated CU DIE using dwarf_offdie or dwarf_offdie_types. This requires the user to know beforehand where to DIE data is stored (in the .debug_info or .debug_types section). For type units