[PATCH] D124082: [Debuginfo][llvm-dwarfdump][dsymutil] Add dsymutil compatibility dump.
Alexey Lapshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 20 03:21:10 PDT 2022
avl created this revision.
avl added reviewers: aprantl, JDevlieghere, clayborg, jhenderson, dblaikie, probinson.
Herald added subscribers: cmtice, hiraditya, mgorny.
Herald added a project: All.
avl requested review of this revision.
Herald added subscribers: llvm-commits, MaskRay.
Herald added a project: LLVM.
This patch adds a new kind of dump into the llvm-dwarfdump utility.
This new kind of dump can be used to compare semantically the same but
binary different DWARF files produced by dsymutil. f.e. these two should match:
dsymutil intput-file -o - | llvm-dwarfdump --dsymutil-compat-dump - -o - | md5
dsymutil --no-odr intput-file -o - | llvm-dwarfdump --dsymutil-compat-dump - -o - | md5
The idea of the dump is that it skips type dies. Instead, it prints type names.
Additionally, it skips dies offsets, strings offsets, etc...
"llvm-dwarfdump -a":
0x0000002a: DW_TAG_class_type
DW_AT_name ("class1")
0x00000071: DW_TAG_subprogram
DW_AT_name ("foo1")
DW_AT_low_pc (0x0000000000001000)
DW_AT_high_pc (0x0000000000001010)
DW_AT_type (0x0000002a "class1")
"llvm-dwarfdump --dsymutil-compat-dump":
== DW_TAG_subprogram [1]
DW_AT_name "foo1"
DW_AT_low_pc 0x0000000000001000
DW_AT_high_pc 0x0000000000001010
DW_AT_type "class1"
use cases for this dump:
1. to compare result produced by "dsymutil" and "dsymutil --no-odr".
2. to compare result produced by current upstream dsymutil and another one from https://reviews.llvm.org/D86539.
3. to compare result produced by current upstream dsymutil and another one from https://reviews.llvm.org/D96035.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D124082
Files:
llvm/include/llvm/DebugInfo/DWARF/DWARFDebugLoc.h
llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/basic.yaml
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/loc.yaml
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/loclists.yaml
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/ranges-error.yaml
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/ranges.yaml
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/rnglists.yaml
llvm/test/tools/llvm-dwarfdump/dsymutil-compat/specification.yaml
llvm/tools/llvm-dwarfdump/CMakeLists.txt
llvm/tools/llvm-dwarfdump/llvm-dwarfdump.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D124082.423860.patch
Type: text/x-patch
Size: 39177 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220420/a774b447/attachment.bin>
More information about the llvm-commits
mailing list