[PATCH] D106624: [DWARF] Don't process .debug_info relocations for DWO Context

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 22 18:09:42 PDT 2023


MaskRay added inline comments.
Herald added a project: All.


================
Comment at: llvm/lib/DebugInfo/DWARF/DWARFContext.cpp:1739
+      if (RelocatedSection == Obj.section_end() ||
+          (IsDWOContext && !Name.contains(".dwo")))
         continue;
----------------
dblaikie wrote:
> dblaikie wrote:
> > How come this tests both these properties? I guess there's some case where `IsDWOContext` is inadequate/isn't correct and the file extension test is needed? What's that case?
> Still curious about this.
This may fire for `.text.dwo` `.rodata.dwo` and create some difficulty for PE/COFF when it adds DWO support (D152785). I created D153602 to adjust the condition.

Also, `ends_with` would be slightly better.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D106624



More information about the llvm-commits mailing list