aboutsummaryrefslogtreecommitdiff
path: root/lib/Linker
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-02-27 22:34:19 +0000
committerBill Wendling <isanbard@gmail.com>2012-02-27 22:34:19 +0000
commitc68d127b2c5a233c5e3f9dd59ca4ab335419d9dd (patch)
tree4734e87d581b4afb6fc8edf1ed4b54fe0a27169c /lib/Linker
parent284a6bbae148e1b5a2696f13526bb8f64da62177 (diff)
The code that cleans up multiple, isomorphic types has a subtle error that
manifests itself when building LLVM with LTO. <rdar://problem/10913281> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@151576 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Linker')
-rw-r--r--lib/Linker/LinkModules.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/Linker/LinkModules.cpp b/lib/Linker/LinkModules.cpp
index 400380926f..59c9d7016b 100644
--- a/lib/Linker/LinkModules.cpp
+++ b/lib/Linker/LinkModules.cpp
@@ -580,7 +580,11 @@ void ModuleLinker::computeTypeMapping() {
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 @@ void ModuleLinker::computeTypeMapping() {
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