[llvm-commits] [llvm] r151576 - /llvm/trunk/lib/Linker/LinkModules.cpp

Bill Wendling isanbard at gmail.com
Mon Feb 27 14:34:19 PST 2012


Author: void
Date: Mon Feb 27 16:34:19 2012
New Revision: 151576

URL: http://llvm.org/viewvc/llvm-project?rev=151576&view=rev
Log:
The code that cleans up multiple, isomorphic types has a subtle error that
manifests itself when building LLVM with LTO.
<rdar://problem/10913281>

Modified:
    llvm/trunk/lib/Linker/LinkModules.cpp

Modified: llvm/trunk/lib/Linker/LinkModules.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Linker/LinkModules.cpp?rev=151576&r1=151575&r2=151576&view=diff
==============================================================================
--- llvm/trunk/lib/Linker/LinkModules.cpp (original)
+++ llvm/trunk/lib/Linker/LinkModules.cpp Mon Feb 27 16:34:19 2012
@@ -580,7 +580,11 @@
     if (GlobalValue *DGV = getLinkedToGlobal(I))
       TypeMap.addTypeMapping(DGV->getType(), I->getType());
   }
-  
+
+#if 0
+  // FIXME: This doesn't play well with LTO. We cannot compile LLVM with this
+  //        enabled. <rdar://problem/10913281>.
+
   // Incorporate types by name, scanning all the types in the source module.
   // At this point, the destination module may have a type "%foo = { i32 }" for
   // example.  When the source module got loaded into the same LLVMContext, if
@@ -610,8 +614,8 @@
       if (!SrcStructTypesSet.count(DST))
         TypeMap.addTypeMapping(DST, ST);
   }
-  
-  
+#endif
+
   // Don't bother incorporating aliases, they aren't generally typed well.
   
   // Now that we have discovered all of the type equivalences, get a body for





More information about the llvm-commits mailing list