diff options
author | Chris Lattner <sabre@nondot.org> | 2004-03-14 20:50:42 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-03-14 20:50:42 +0000 |
commit | fd72bed301ed3336f58144c1377d48d97064a65a (patch) | |
tree | fa9cb8eccff799e5d99d36e3656b6db125f23aa2 /llvm/tools/bugpoint/ExtractFunction.cpp | |
parent | 4837f6c0d9222d2d54dbff96b0ca05c3527cc630 (diff) | |
download | bcm5719-llvm-fd72bed301ed3336f58144c1377d48d97064a65a.tar.gz bcm5719-llvm-fd72bed301ed3336f58144c1377d48d97064a65a.zip |
Refactor and clean up a bunch more code. No major functionality changes.
* Make several methods of bugdriver global functions (ParseInputFile, PrintFunctionList)
* Make PrintFunctionList truncate the output after 10 entries, like the crash debugger
did. This allows code sharing.
* Add a couple of methods to BugDriver that allows us to eliminate some friends
* Improve comments in ExtractFunction.cpp
* Make classes that used to be friends up bugdriver now live in anon namespaces
* Rip a bunch of functionality in the miscompilation tester into a new
TestMergedProgram function for future code sharing.
* Fix a bug in the miscompilation tester induced in my last checkin
llvm-svn: 12393
Diffstat (limited to 'llvm/tools/bugpoint/ExtractFunction.cpp')
-rw-r--r-- | llvm/tools/bugpoint/ExtractFunction.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/tools/bugpoint/ExtractFunction.cpp b/llvm/tools/bugpoint/ExtractFunction.cpp index 8e392613c93..22bd1738952 100644 --- a/llvm/tools/bugpoint/ExtractFunction.cpp +++ b/llvm/tools/bugpoint/ExtractFunction.cpp @@ -7,8 +7,8 @@ // //===----------------------------------------------------------------------===// // -// This file implements a method that extracts a function from program, cleans -// it up, and returns it as a new module. +// This file implements several methods that are used to extract functions, +// loops, or portions of a module from the rest of the module. // //===----------------------------------------------------------------------===// @@ -76,6 +76,8 @@ Module *BugDriver::deleteInstructionFromProgram(const Instruction *I, // Make sure that the appropriate target data is always used... Passes.add(new TargetData("bugpoint", Result)); + /// FIXME: If this used runPasses() like the methods below, we could get rid + /// of the -disable-* options! if (Simplification > 1 && !NoDCE) Passes.add(createDeadCodeEliminationPass()); if (Simplification && !DisableSimplifyCFG) |