diff options
author | Chris Lattner <sabre@nondot.org> | 2003-10-14 21:09:11 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-10-14 21:09:11 +0000 |
commit | a0f5b15e1eb8642d92b3141a6b88a5729ea979dc (patch) | |
tree | b0656b9b29ae1e9d9460150a407bc79d5bec257d /tools/bugpoint/ExecutionDriver.cpp | |
parent | 1798e4ade88c1fccfc290846f588c1d1261a5299 (diff) | |
download | llvm-a0f5b15e1eb8642d92b3141a6b88a5729ea979dc.tar.gz llvm-a0f5b15e1eb8642d92b3141a6b88a5729ea979dc.tar.bz2 llvm-a0f5b15e1eb8642d92b3141a6b88a5729ea979dc.tar.xz |
The return value of compileSharedObject was never used. Return the shared
object's name instead
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9120 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/bugpoint/ExecutionDriver.cpp')
-rw-r--r-- | tools/bugpoint/ExecutionDriver.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/tools/bugpoint/ExecutionDriver.cpp b/tools/bugpoint/ExecutionDriver.cpp index f941713b3a..17e2ce2378 100644 --- a/tools/bugpoint/ExecutionDriver.cpp +++ b/tools/bugpoint/ExecutionDriver.cpp @@ -135,16 +135,16 @@ std::string BugDriver::executeProgramWithCBE(std::string OutputFile, return executeProgram(OutputFile, BytecodeFile, SharedObject, cbe); } -int BugDriver::compileSharedObject(const std::string &BytecodeFile, - std::string &SharedObject) { +std::string BugDriver::compileSharedObject(const std::string &BytecodeFile) { assert(Interpreter && "Interpreter should have been created already!"); - std::string Message, OutputCFile; + std::string OutputCFile; // Using CBE cbe->OutputC(BytecodeFile, OutputCFile); #if 0 /* This is an alternative, as yet unimplemented */ // Using LLC + std::string Message; LLC *llc = createLLCtool(Message); if (llc->OutputAsm(BytecodeFile, OutputFile)) { std::cerr << "Could not generate asm code with `llc', exiting.\n"; @@ -152,12 +152,14 @@ int BugDriver::compileSharedObject(const std::string &BytecodeFile, } #endif - gcc->MakeSharedObject(OutputCFile, CFile, SharedObject); + std::string SharedObjectFile; + if (gcc->MakeSharedObject(OutputCFile, CFile, SharedObject)) + exit(1); // Remove the intermediate C file removeFile(OutputCFile); - return 0; + return SharedObjectFile; } |