Add functions that return instances of these printer passes
authorBrian Gaeke <gaeke@uiuc.edu>
Mon, 26 Apr 2004 16:27:08 +0000 (16:27 +0000)
committerBrian Gaeke <gaeke@uiuc.edu>
Mon, 26 Apr 2004 16:27:08 +0000 (16:27 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13175 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/CFGPrinter.cpp

index ac78970cc29db2a53f34b75bbbe37def20e1511a..3423e8be78c764c8fecbe4b377fcf2764ff58f4c 100644 (file)
@@ -22,6 +22,7 @@
 #include "llvm/Function.h"
 #include "llvm/iTerminators.h"
 #include "llvm/Assembly/Writer.h"
+#include "llvm/Analysis/CFGPrinter.h"
 #include "llvm/Support/CFG.h"
 #include <sstream>
 #include <fstream>
@@ -173,3 +174,12 @@ void Function::viewCFGOnly() const {
   viewCFG();
   CFGOnly = false;
 }
+
+FunctionPass *llvm::createCFGPrinterPass () {
+  return new CFGPrinter();
+}
+
+FunctionPass *llvm::createCFGOnlyPrinterPass () {
+  return new CFGOnlyPrinter();
+}
+