[PATCH] D21779: [LTO] Infer EKind/EMachine from Bitcode files

Davide Italiano via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 28 20:56:58 PDT 2016


davide added a comment.

Another possibility is to pass the triple to the function so that the computation of the triple from MemoryBuffer is shared in the constructor. I can change if you like that better.


================
Comment at: ELF/InputFiles.cpp:723
@@ -681,3 +722,3 @@
   std::unique_ptr<InputFile> F;
   if (isBitcode(MB))
     F.reset(new BitcodeFile(MB));
----------------
Used, thanks Mehdi!

================
Comment at: ELF/InputFiles.cpp:737
@@ -695,3 +736,3 @@
   if (Seen)
     return MemoryBufferRef();
   Seen = true;
----------------
Yes, unfortunately :( At least now we error out so we should able to catch those. I talked briefly with Rafael on IRC and he said we probably need a switch(), hopefully we can move away from it at some point.


http://reviews.llvm.org/D21779





More information about the llvm-commits mailing list