diff options
author | Pavel Labath <labath@google.com> | 2018-05-24 12:12:49 +0000 |
---|---|---|
committer | Pavel Labath <labath@google.com> | 2018-05-24 12:12:49 +0000 |
commit | b7b2424f2e2a9b866980547920c78c3de159bb9a (patch) | |
tree | 525fbca093eb05ac49abac524ff76588751fea0d /clang/unittests/Basic/VirtualFileSystemTest.cpp | |
parent | 93d7b130f900d2b3b5f8fb4fd1659b40676e7e34 (diff) | |
download | llvm-b7b2424f2e2a9b866980547920c78c3de159bb9a.zip llvm-b7b2424f2e2a9b866980547920c78c3de159bb9a.tar.gz llvm-b7b2424f2e2a9b866980547920c78c3de159bb9a.tar.bz2 |
DWARF: Move indexing code from DWARFUnit to ManualDWARFIndex
Summary:
I think this makes sense for several reasons:
- better separation of concerns: DWARFUnit's job should be to provide a
nice interface to its users to access the unit contents.
ManualDWARFIndex can then use this interface to build an index and
provide it to its users.
- closer alignment with llvm parsers: there is no indexing equivalent in
llvm, and there probably never will be, as the index is very centered
around how lldb wants to access debug info. If we ever switch to
llvm's parser, this will allow us swap out DWARFUnit implementations
and keep indexing as-is.
- closer proximity of the indexing code to AppleDWARFIndex will make it
easier to keep the two in sync (e.g. right now the two use very
different algorithms to determine whether a DW_TAG_subroutine
represents a "method"). This is my primary motivation for making this
change now, but I am leaving this work to a separate patch.
The only interface change to DWARFUnit I needed to make was to add an
efficient way to iterate over the list of all DIEs. Adding this also
aligns us closer to the llvm parser.
Reviewers: JDevlieghere, clayborg, aprantl
Subscribers: lldb-commits
Differential Revision: https://reviews.llvm.org/D47253
llvm-svn: 333178
Diffstat (limited to 'clang/unittests/Basic/VirtualFileSystemTest.cpp')
0 files changed, 0 insertions, 0 deletions