]> granicus.if.org Git - clang/commitdiff
Revert "[ThinLTO] Ensure we always select the same function copy to import"
authorTeresa Johnson <tejohnson@google.com>
Sat, 14 Jul 2018 01:50:14 +0000 (01:50 +0000)
committerTeresa Johnson <tejohnson@google.com>
Sat, 14 Jul 2018 01:50:14 +0000 (01:50 +0000)
This reverts commit r337051.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@337082 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/BackendUtil.cpp

index 226a27b2161df76712f0e40552fb0d70bb3dcf3c..2a02b838d22ab963cc442a5d0226ad8a03ef1204 100644 (file)
@@ -1127,8 +1127,9 @@ static void runThinLTOBackend(ModuleSummaryIndex *CombinedIndex, Module *M,
     // e.g. record required linkage changes.
     if (Summary->modulePath() == M->getModuleIdentifier())
       continue;
-    // Add an entry to provoke importing by thinBackend.
-    ImportList[Summary->modulePath()].insert(GUID);
+    // Doesn't matter what value we plug in to the map, just needs an entry
+    // to provoke importing by thinBackend.
+    ImportList[Summary->modulePath()][GUID] = 1;
   }
 
   std::vector<std::unique_ptr<llvm::MemoryBuffer>> OwnedImports;