[all-commits] [llvm/llvm-project] 529614: [DWARFDump] Make --verify handle all sections by d...
Felipe de Azevedo Piovezan via All-commits
all-commits at lists.llvm.org
Tue Feb 13 13:20:37 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 52961491ca347e7c8766dc7c45841bacac6a4470
https://github.com/llvm/llvm-project/commit/52961491ca347e7c8766dc7c45841bacac6a4470
Author: Felipe de Azevedo Piovezan <fpiovezan at apple.com>
Date: 2024-02-13 (Tue, 13 Feb 2024)
Changed paths:
M llvm/test/DebugInfo/X86/dwarfdump-str-offsets.s
M llvm/test/DebugInfo/X86/skeleton-unit-verify.s
M llvm/test/tools/llvm-dwarfdump/X86/verify_file_encoding.yaml
M llvm/test/tools/llvm-dwarfutil/ELF/X86/dwarf5-macro.test
M llvm/tools/llvm-dwarfdump/llvm-dwarfdump.cpp
Log Message:
-----------
[DWARFDump] Make --verify handle all sections by default (#81559)
The current behavior of --verify is that it only verifies debug_info,
debug_abbrev and debug_names. This seems fairly arbitrary and might have
been unintentional, as originally the absence of any section flags
implied "all".
This patch changes the behavior so that the verifier now verifies
everything by default. It revealed two tests that had potentially
invalid DWARF:
1. dwarfdump-str-offsets.s is adding padding between two
debug_str_offset contributions. The standard does not explicitly allow
this behavior. See issue
https://github.com/llvm/llvm-project/issues/81558
2. dwarf5-macro.test uses a checked-in binary that has invalid
debug_str_offsets. One of its entries points to the _middle_ of the
string section:
error: .debug_str_offsets: contribution 0x0: index 0x4: invalid string
offset *0x18 == 0x455D, is neither zero nor immediately following a null
character
If we look at the closest offset to 0x455D in debug_str:
```
0x0000454e: "__SLONG32_TYPE int"
```
0x455D points to "int".
More information about the All-commits
mailing list