From b1d4a39990f0abcd323cdb5631f46101d3e4e867 Mon Sep 17 00:00:00 2001 From: Teresa Johnson Date: Mon, 2 Nov 2015 21:39:10 +0000 Subject: Support for ThinLTO function importing and symbol linking. Summary: Support for necessary linkage changes and symbol renaming during ThinLTO function importing. Also includes llvm-link support for manually importing functions and associated llvm-link based tests. Note that this does not include support for intelligently importing metadata, which is currently imported duplicate times. That support will be in the follow-on patch, and currently is ignored by the tests. Reviewers: dexonsmith, joker.eph, davidxl Subscribers: tobiasvk, tejohnson, llvm-commits Differential Revision: http://reviews.llvm.org/D13515 llvm-svn: 251837 --- llvm/lib/Bitcode/Reader/BitcodeReader.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp') diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp index 1a63e08f6671..4b8b554b252e 100644 --- a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp +++ b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp @@ -5813,12 +5813,12 @@ llvm::getBitcodeTargetTriple(MemoryBufferRef Buffer, LLVMContext &Context, ErrorOr> llvm::getFunctionInfoIndex(MemoryBufferRef Buffer, LLVMContext &Context, DiagnosticHandlerFunction DiagnosticHandler, - bool IsLazy) { + const Module *ExportingModule, bool IsLazy) { std::unique_ptr Buf = MemoryBuffer::getMemBuffer(Buffer, false); FunctionIndexBitcodeReader R(Buf.get(), Context, DiagnosticHandler, IsLazy); std::unique_ptr Index = - llvm::make_unique(); + llvm::make_unique(ExportingModule); auto cleanupOnError = [&](std::error_code EC) { R.releaseBuffer(); // Never take ownership on error. -- cgit v1.2.3