Revert "Support for ThinLTO function importing and symbol linking."
This reverts commit r251837, due to a number of bot failures of the form: /home/grosser/buildslave/perf-x86_64-penryn-O3-polly-fast/llvm.obj/tools/llvm-link/Release+Asserts/llvm-link.o:llvm-link.cpp:function loadIndex(llvm::LLVMContext&, llvm::Module const*): error: undefined reference to 'llvm::object::FunctionIndexObjectFile::create(llvm::MemoryBufferRef, llvm::LLVMContext&, llvm::Module const*, bool)' /home/grosser/buildslave/perf-x86_64-penryn-O3-polly-fast/llvm.obj/tools/llvm-link/Release+Asserts/llvm-link.o:llvm-link.cpp:function loadIndex(llvm::LLVMContext&, llvm::Module const*): error: undefined reference to 'llvm::object::FunctionIndexObjectFile::takeIndex()' I'm not sure why these are happening - I added Object to the requred libraries in tools/llvm-link/LLVMBuild.txt and the LLVM_LINK_COMPONENTS in tools/llvm-link/CMakeLists.txt. Confirmed for my build that these symbols come out of libLLVMObject.a. What am I missing? llvm-svn: 251841
This commit is contained in:
@@ -5813,12 +5813,12 @@ llvm::getBitcodeTargetTriple(MemoryBufferRef Buffer, LLVMContext &Context,
|
||||
ErrorOr<std::unique_ptr<FunctionInfoIndex>>
|
||||
llvm::getFunctionInfoIndex(MemoryBufferRef Buffer, LLVMContext &Context,
|
||||
DiagnosticHandlerFunction DiagnosticHandler,
|
||||
const Module *ExportingModule, bool IsLazy) {
|
||||
bool IsLazy) {
|
||||
std::unique_ptr<MemoryBuffer> Buf = MemoryBuffer::getMemBuffer(Buffer, false);
|
||||
FunctionIndexBitcodeReader R(Buf.get(), Context, DiagnosticHandler, IsLazy);
|
||||
|
||||
std::unique_ptr<FunctionInfoIndex> Index =
|
||||
llvm::make_unique<FunctionInfoIndex>(ExportingModule);
|
||||
llvm::make_unique<FunctionInfoIndex>();
|
||||
|
||||
auto cleanupOnError = [&](std::error_code EC) {
|
||||
R.releaseBuffer(); // Never take ownership on error.
|
||||
|
||||
Reference in New Issue
Block a user