It seems that clang in version 14 utilize more advanced features from DWARF5, so I add their support to my dwarfdump. IMHO most exciting features are:
Section .debug_line_str
Section .debug_str_offsets
<0><c>: Abbrev Number: 1 (DW_TAG_compile_unit)
<d> DW_AT_producer : (indexed string: 0): clang version 14.0.6 (git@github.com:github/semmle-code 5c87e7737f331823ed8ed280883888566f08cdea)
<e> DW_AT_language : 33 (C++14)
<10> DW_AT_name : (indexed string: 0x1): c/extractor/src/extractor.cpp
<11> DW_AT_str_offsets_base: 0x8
As you can see here 2 tags have names before we have value of string base. Much harder to parse in one pass now
New locations format
Offset Entry 2077
This cryptic message means that starting from address 0x4fb3c5 (note - most tools like objdump or llvm-dwarfdump cannot correctly show this new locations, in this case objdump showed address in bad format) some local variable located in register rdi until next address range. Seems that both IDA Pro and Binary Ninja cannot use this debug information:
0024ef56 00000000000006b4 (index into .debug_addr) 004fb3c500000000 (base address)
0024ef59 0000000000000000 000000000000001c DW_OP_reg5 (rdi).text:00004FB3C5 mov rdi, cs:compilation_tf
Global var compilation_tf has type a_trap_file_ptr - pointer to a_trap_file. IDA Pro has that types information from debug info but anyway cannot show access to field of a_trap_file at offset 0xC for next instruction
.text:00004FB3CC cmp dword ptr [rdi+0Ch], 0