diff options
author | Pavel Labath <pavel@labath.sk> | 2019-11-19 15:14:59 +0100 |
---|---|---|
committer | Pavel Labath <pavel@labath.sk> | 2019-11-21 11:55:21 +0100 |
commit | f65cfff605f2fd802fc337c6152474e3f3d22a1c (patch) | |
tree | aadfe16fefb4418cb1ed354419a1139efdce93b9 /lldb/packages/Python/lldbsuite/test/python_api/interpreter/TestRunCommandInterpreterAPI.py | |
parent | d9cb1b34e068be18768bb0533d5a157397e62838 (diff) | |
download | bcm5719-llvm-f65cfff605f2fd802fc337c6152474e3f3d22a1c.tar.gz bcm5719-llvm-f65cfff605f2fd802fc337c6152474e3f3d22a1c.zip |
dwarfdump --statistics: Use new location list api
Summary:
This patch removes manual location list handling in the statistics code
and replaces it with the new DWARFDie api, which provides access to a
"cooked" location list. This has the following effects:
- the code now properly handles split-dwarf location lists
- it will automatically support dwarf5 location lists once support for
those is added
- it properly handles location lists with base address selection entries
- it fixes a bug where the location list code was using the first
DW_AT_ranges range as a "base address" of the compile unit (it should
have used DW_AT_low_pc instead. The effect of this was that the
computation of the start address of a variable in its scope was broken
for these kinds of compile units. This only manifested itself on
linked files, since in object files the first DW_AT_ranges range
normally starts at 0.
Since pretty much every kind of location list was broken in some way,
it's hard to verify that the new implementation is correct -- the output
will be different in all non-trivial cases, and mostly with good reason.
Most of the existing statistics tests continue to pass though, and a
visual inspection of the statistics for non-trivial inputs shows that
the data is more "reasonable" now. I have updated the "dwo statistics"
test to include the new numbers, as the previous ones were completely
bogus, and I have added a targeted test for the "base address" bug.
Reviewers: dblaikie, cmtice, vsk
Subscribers: aprantl, SouraVX, JDevlieghere, djtodoro, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D70444
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/python_api/interpreter/TestRunCommandInterpreterAPI.py')
0 files changed, 0 insertions, 0 deletions