From: Chris Lattner Date: Sat, 14 Jan 2006 19:17:02 +0000 (+0000) Subject: add a dump method to CallGraph X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=1694ec615f71e25de6d07ffc6fe29deed353c657;p=oota-llvm.git add a dump method to CallGraph git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25314 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/Analysis/CallGraph.h b/include/llvm/Analysis/CallGraph.h index 4edb6023562..e477be34f8e 100644 --- a/include/llvm/Analysis/CallGraph.h +++ b/include/llvm/Analysis/CallGraph.h @@ -147,7 +147,8 @@ public: void initialize(Module &M); virtual void print(std::ostream &o, const Module *M) const; - + void dump() const; + // stub - dummy function, just ignore it static void stub(); protected: diff --git a/lib/Analysis/IPA/CallGraph.cpp b/lib/Analysis/IPA/CallGraph.cpp index 03f73fa8d20..29b8ed4a7f0 100644 --- a/lib/Analysis/IPA/CallGraph.cpp +++ b/lib/Analysis/IPA/CallGraph.cpp @@ -216,6 +216,10 @@ void CallGraph::print(std::ostream &OS, const Module *M) const { I->second->print(OS); } +void CallGraph::dump() const { + print(std::cerr, 0); +} + //===----------------------------------------------------------------------===// // Implementations of public modification methods //