[Lldb-commits] [PATCH] D67390: [LLDB][ELF] Load both, .symtab and .dynsym sections

Konrad Wilhelm Kleine via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Sep 11 03:15:51 PDT 2019


kwk marked 3 inline comments as done.
kwk added a comment.

@labath I've addressed your comment rewrites in a fixup commit that I've commited without a review (llvm-svn: 371600):  https://reviews.llvm.org/rLLDB371600



================
Comment at: lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp:2668-2671
+      if (!m_symtab_up) {
+        auto sec = symtab ? symtab : dynsym;
+        m_symtab_up.reset(new Symtab(sec->GetObjectFile()));
+      }
----------------
labath wrote:
> I wouldn't bother with this. You can just unconditionally create a Symtab object before you start parsing any symbol tables.
I don't fully agree that it is that simple because further down in the code we do check for `if (m_symtab_up == nullptr)` and that is a condition I need to respect because of relocation, don't I?


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67390/new/

https://reviews.llvm.org/D67390





More information about the lldb-commits mailing list