Revert "Fix overly aggressive type merging."
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Thu, 27 Nov 2014 17:01:10 +0000 (17:01 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Thu, 27 Nov 2014 17:01:10 +0000 (17:01 +0000)
commitc586eaa1f15e21b08c799148860d400cd3d1d002
treee8979dfa95fb3ef698f9ec4ae7081915e860219f
parentc7d4b8dceca8d896299b16a52efbc2d4bb4d22ae
Revert "Fix overly aggressive type merging."

This reverts commit r222727, which causes LTO bootstrap failures.

Last passing @ r222698:
http://lab.llvm.org:8080/green/job/clang-Rlto_master_build/532/

First failing @ r222843:
http://lab.llvm.org:8080/green/job/clang-Rlto_master_build/533/

Internal bootstraps pointed at a much narrower range: r222725 is
passing, and r222731 is failing.

LTO crashes while handling libclang.dylib:
http://lab.llvm.org:8080/green/job/clang-Rlto_master_build/533/consoleFull#-158682280549ba4694-19c4-4d7e-bec5-911270d8a58c

    GEP is not of right type for indices!
      %InfoObj.i.i = getelementptr inbounds %"class.llvm::OnDiskIterableChainedHashTable"* %.lcssa, i64 0, i32 0, i32 4, !dbg !123627
     %"class.clang::serialization::reader::ASTIdentifierLookupTrait" = type { %"class.clang::ASTReader.31859"*, %"class.clang::serialization::ModuleFile.31870"*, %"class.clang::IdentifierInfo"* }LLVM ERROR: Broken function found, compilation aborted!
    clang: error: linker command failed with exit code 1 (use -v to see invocation)

Looks like the new algorithm doesn't merge types aggressively enough.

llvm-svn: 222895
llvm/lib/Linker/LinkModules.cpp
llvm/test/Linker/Inputs/type-unique-opaque.ll [deleted file]
llvm/test/Linker/type-unique-opaque.ll [deleted file]