[PATCH] D70394: [DWARF] Add an api to get "interpreted" location lists
David Blaikie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 19 11:47:45 PST 2019
dblaikie accepted this revision.
dblaikie added inline comments.
This revision is now accepted and ready to land.
================
Comment at: llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp:56-67
+ std::vector<uint8_t> Loclists{
+ 0, 0, 0, 0, 5, 0, 4, 0, 0, 0, 0, 0, // Header
+ // First location list.
+ DW_LLE_start_length, 1, 0, 0, 0, 2, 0, // First entry.
+ DW_LLE_end_of_list,
+ // Second location list.
+ DW_LLE_startx_length, 1, 2, 0, // First entry.
----------------
Maybe break this down a bit further by field? (0, 0, 0, 0 // length \ 5 // version, etc... including for the location expressions? Otherwise the strings of zeros especially (& random 2s?) are a bit opaque)
================
Comment at: llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp:66
+ DW_LLE_start_length, 1, 0, 0, 0, 2, 0, // First entry.
+ // No end of list.
+ };
----------------
"intentionally missing end of list entry to test error handling" (maybe that's too verbose - but as it stands, just "no end of list" is a bit confusing to me - it's not clear why that's the case/being highlighted)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D70394/new/
https://reviews.llvm.org/D70394
More information about the llvm-commits
mailing list