[PATCH] D38409: [dwarfdump] Add -lookup option

Jonas Devlieghere via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 2 06:43:45 PDT 2017


JDevlieghere added inline comments.


================
Comment at: include/llvm/DebugInfo/DIContext.h:64
+    OS << "Line info: ";
+    if (FileName != "<invalid>")
+      OS << "file '" << FileName << "', ";
----------------
aprantl wrote:
> optimization opportunity: this and the fact that we initialize the std::string with "<invalid>" seems kind of expensive. Perhaps switch to StringRef and handle the empty string in dump()?
What exactly o you want to switch to StringRef? Do you mean storing an empty string and having a getter that returns it as a StringRef or "<invalid>" if it's empty? 


Repository:
  rL LLVM

https://reviews.llvm.org/D38409





More information about the llvm-commits mailing list