[LTO][ThinLTO] Use the linker resolutions to mark global values as dso_local.
authorSean Fertile <sfertile@ca.ibm.com>
Fri, 3 Nov 2017 21:45:55 +0000 (21:45 +0000)
committerSean Fertile <sfertile@ca.ibm.com>
Fri, 3 Nov 2017 21:45:55 +0000 (21:45 +0000)
commit36528c2a9b3d37d6692de5738697598abfb5d9c8
tree2729d6a8bd507a1de66862d7869fb4ef8ade7868
parent3fc9188fa8cb939539e568a0ef602892aa3fc59a
[LTO][ThinLTO] Use the linker resolutions to mark global values as dso_local.

Now that we have a way to mark GlobalValues as local we can use the symbol
resolutions that the linker plugin provides as part of lto/thinlto link
step to refine the compilers view on what symbols will end up being local.

Differential Revision: https://reviews.llvm.org/D35702

llvm-svn: 317374
19 files changed:
llvm/include/llvm/IR/ModuleSummaryIndex.h
llvm/include/llvm/IR/ModuleSummaryIndexYAML.h
llvm/lib/Analysis/ModuleSummaryAnalysis.cpp
llvm/lib/Bitcode/Reader/BitcodeReader.cpp
llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
llvm/lib/LTO/LTO.cpp
llvm/lib/Transforms/Utils/FunctionImportUtils.cpp
llvm/test/Bitcode/thinlto-summary-local-5.0.ll [new file with mode: 0644]
llvm/test/Bitcode/thinlto-summary-local-5.0.ll.bc [new file with mode: 0644]
llvm/test/LTO/Resolution/X86/comdat-mixed-lto.ll
llvm/test/LTO/Resolution/X86/comdat.ll
llvm/test/LTO/Resolution/X86/commons.ll
llvm/test/ThinLTO/X86/deadstrip.ll
llvm/test/ThinLTO/X86/funcimport2.ll
llvm/test/ThinLTO/X86/internalize.ll
llvm/test/ThinLTO/X86/reference_non_importable.ll
llvm/test/Transforms/LowerTypeTests/import-unsat.ll
llvm/test/Transforms/PGOProfile/thinlto_samplepgo_icp2.ll
llvm/test/Transforms/WholeProgramDevirt/import-indir.ll