[PATCH] D25495: [ThinLTO] Avoid archive member collisions

Davide Italiano via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 12 11:06:52 PDT 2016


davide added inline comments.


================
Comment at: ELF/InputFiles.cpp:726-727
+  Obj = check(lto::InputFile::create(MemoryBufferRef(
+      MB.getBuffer(), Saver.save(ArchiveName + MB.getBufferIdentifier() +
+                                 utostr(OffsetInArchive)))));
   DenseSet<const Comdat *> KeptComdats;
----------------
ruiu wrote:
> Can you use the object address as a unique identifier instead? I mean `utostr((uint64_t)&MB)` is always unique.
Maybe, but I'd like to double check with Peter to make sure it's fine on `lib/LTO` side (probably it is).


https://reviews.llvm.org/D25495





More information about the llvm-commits mailing list