]> granicus.if.org Git - llvm/commit
Apply summary-based dead stripping to regular LTO modules with summaries.
authorPeter Collingbourne <peter@pcc.me.uk>
Thu, 15 Jun 2017 17:26:13 +0000 (17:26 +0000)
committerPeter Collingbourne <peter@pcc.me.uk>
Thu, 15 Jun 2017 17:26:13 +0000 (17:26 +0000)
commit95d9f1b4f9b749a1843b4e9bd90413248112091b
treecaa7e50b45c57db227ef9bde54be9b44bfefca2b
parent52ffcca2b54a79b810654d1a70d51161570a2f98
Apply summary-based dead stripping to regular LTO modules with summaries.

If a regular LTO module has a summary index, then instead of linking
it into the combined regular LTO module right away, add it to the
combined summary index and associate it with a special module that
represents the combined regular LTO module.

Any such modules are linked during LTO::run(), at which time we use
the results of summary-based dead stripping to control whether to
link prevailing symbols.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@305482 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Bitcode/BitcodeReader.h
include/llvm/IR/ModuleSummaryIndex.h
include/llvm/LTO/LTO.h
lib/Bitcode/Reader/BitcodeReader.cpp
lib/IR/ModuleSummaryIndex.cpp
lib/LTO/LTO.cpp
lib/LTO/LTOModule.cpp
test/LTO/Resolution/X86/Inputs/dead-strip-fulllto.ll [new file with mode: 0644]
test/LTO/Resolution/X86/dead-strip-fulllto.ll [new file with mode: 0644]