[PATCH] D115973: [llvm-profgen] Support symbol loading for debug fission

Alexander Yermolovich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 23 11:23:02 PST 2021


ayermolo added inline comments.


================
Comment at: llvm/tools/llvm-profgen/ProfiledBinary.cpp:48
+    DWPPath("dwp", cl::init(""), cl::ZeroOrMore,
+            cl::desc("Path of split dwarf .dwp/.dwo/.o file."));
+
----------------
wlei wrote:
> ayermolo wrote:
> > There is one DWP file. There could be multiple .o/.dwo files in multiple directories. I don't think this option makes sense for the latter. The path to those should be encoded in DWARF CUs.
> > Also for DWP it's not exactly a path, but fully resolved path+filename
> > auto Obj = object::ObjectFile::createObjectFile(
> >           this->DWPName.empty()
> >               ? (DObj->getFileName() + ".dwp").toStringRef(DWPName)
> >               : StringRef(this->DWPName));
> Thanks! I see, while I was creating the test cases, I found that ".o and .dwo" were all encoded in absolute paths, then the tests will fail in others' machine, so I used this "-dwp" as a workaround to find the .o/.dwo file.
> For this reason, how about that we give warning while using "-dwp" for .o and .dwo path?
> 
> > Also for DWP it's not exactly a path, but fully resolved path+filename
> 
> I see, so even if the DWP path is missing, it can search the dwp in the same directory of obj file with ".dwp" suffix. Updated its description.
Warning seems like an overkill. Presumably people know what they are doing. I don't have a strong opinion one way or the other.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D115973



More information about the llvm-commits mailing list