diff options
Diffstat (limited to 'llvm/tools')
-rw-r--r-- | llvm/tools/bugpoint/BugDriver.cpp | 2 | ||||
-rw-r--r-- | llvm/tools/bugpoint/Miscompilation.cpp | 10 |
2 files changed, 5 insertions, 7 deletions
diff --git a/llvm/tools/bugpoint/BugDriver.cpp b/llvm/tools/bugpoint/BugDriver.cpp index b54ea2387b3..b8be17e44dd 100644 --- a/llvm/tools/bugpoint/BugDriver.cpp +++ b/llvm/tools/bugpoint/BugDriver.cpp @@ -126,7 +126,7 @@ bool BugDriver::addSources(const std::vector<std::string> &Filenames) { if (!M.get()) return true; outs() << "Linking in input file: '" << Filenames[i] << "'\n"; - if (Linker::LinkModules(Program, M.get(), Linker::DestroySource)) + if (Linker::LinkModules(Program, M.get())) return true; } diff --git a/llvm/tools/bugpoint/Miscompilation.cpp b/llvm/tools/bugpoint/Miscompilation.cpp index ce16d4d18af..8cb45838773 100644 --- a/llvm/tools/bugpoint/Miscompilation.cpp +++ b/llvm/tools/bugpoint/Miscompilation.cpp @@ -222,7 +222,7 @@ static Module *TestMergedProgram(const BugDriver &BD, Module *M1, Module *M2, M1 = CloneModule(M1); M2 = CloneModule(M2); } - if (Linker::LinkModules(M1, M2, Linker::DestroySource)) + if (Linker::LinkModules(M1, M2)) exit(1); delete M2; // We are done with this module. @@ -392,8 +392,7 @@ static bool ExtractLoops(BugDriver &BD, F->getFunctionType())); } - if (Linker::LinkModules(ToNotOptimize, ToOptimizeLoopExtracted, - Linker::DestroySource)) + if (Linker::LinkModules(ToNotOptimize, ToOptimizeLoopExtracted)) exit(1); MiscompiledFunctions.clear(); @@ -422,8 +421,7 @@ static bool ExtractLoops(BugDriver &BD, // extraction both didn't break the program, and didn't mask the problem. // Replace the current program with the loop extracted version, and try to // extract another loop. - if (Linker::LinkModules(ToNotOptimize, ToOptimizeLoopExtracted, - Linker::DestroySource)) + if (Linker::LinkModules(ToNotOptimize, ToOptimizeLoopExtracted)) exit(1); delete ToOptimizeLoopExtracted; @@ -601,7 +599,7 @@ static bool ExtractBlocks(BugDriver &BD, MisCompFunctions.push_back(std::make_pair(I->getName(), I->getFunctionType())); - if (Linker::LinkModules(ProgClone, Extracted.get(), Linker::DestroySource)) + if (Linker::LinkModules(ProgClone, Extracted.get())) exit(1); // Set the new program and delete the old one. |