[llvm-commits] CVS: llvm/tools/bugpoint/ExtractFunction.cpp

Chris Lattner lattner at cs.uiuc.edu
Sun Sep 19 21:48:16 PDT 2004



Changes in directory llvm/tools/bugpoint:

ExtractFunction.cpp updated: 1.38 -> 1.39
---
Log message:

'Pass' should now not be derived from by clients.  Instead, they should derive
from ModulePass.  Instead of implementing Pass::run, then should implement 
ModulePass::runOnModule.



---
Diffs of the changes:  (+3 -3)

Index: llvm/tools/bugpoint/ExtractFunction.cpp
diff -u llvm/tools/bugpoint/ExtractFunction.cpp:1.38 llvm/tools/bugpoint/ExtractFunction.cpp:1.39
--- llvm/tools/bugpoint/ExtractFunction.cpp:1.38	Wed Sep  1 17:55:37 2004
+++ llvm/tools/bugpoint/ExtractFunction.cpp	Sun Sep 19 23:48:05 2004
@@ -211,14 +211,14 @@
   /// BlockExtractorPass - This pass is used by bugpoint to extract all blocks
   /// from the module into their own functions except for those specified by the
   /// BlocksToNotExtract list.
-  class BlockExtractorPass : public Pass {
-    bool run(Module &M);
+  class BlockExtractorPass : public ModulePass {
+    bool runOnModule(Module &M);
   };
   RegisterOpt<BlockExtractorPass>
   XX("extract-bbs", "Extract Basic Blocks From Module (for bugpoint use)");
 }
 
-bool BlockExtractorPass::run(Module &M) {
+bool BlockExtractorPass::runOnModule(Module &M) {
   std::set<BasicBlock*> TranslatedBlocksToNotExtract;
   for (unsigned i = 0, e = BlocksToNotExtract.size(); i != e; ++i) {
     BasicBlock *BB = BlocksToNotExtract[i];






More information about the llvm-commits mailing list