LLVM API Documentation
#include <CallGraph.h>
Collaboration diagram for llvm::CallGraphNode:
Public Types | |
typedef std::vector< CallGraphNode * >::iterator | iterator |
typedef std::vector< CallGraphNode * >::const_iterator | const_iterator |
Public Member Functions | |
Function * | getFunction () const |
iterator | begin () |
iterator | end () |
const_iterator | begin () const |
const_iterator | end () const |
unsigned | size () const |
CallGraphNode * | operator[] (unsigned i) const |
void | dump () const |
void | print (std::ostream &OS) const |
void | removeAllCalledFunctions () |
void | addCalledFunction (CallGraphNode *M) |
void | removeCallEdgeTo (CallGraphNode *Callee) |
void | removeAnyCallEdgeTo (CallGraphNode *Callee) |
CallGraphNode (Function *f) | |
Friends | |
class | CallGraph |
Definition at line 168 of file CallGraph.h.
typedef std::vector<CallGraphNode*>::const_iterator llvm::CallGraphNode::const_iterator |
Definition at line 179 of file CallGraph.h.
typedef std::vector<CallGraphNode*>::iterator llvm::CallGraphNode::iterator |
Definition at line 178 of file CallGraph.h.
llvm::CallGraphNode::CallGraphNode | ( | Function * | f | ) | [inline] |
Definition at line 229 of file CallGraph.h.
void llvm::CallGraphNode::addCalledFunction | ( | CallGraphNode * | M | ) | [inline] |
addCalledFunction add a function to the list of functions called by this one.
Definition at line 212 of file CallGraph.h.
References M.
Referenced by llvm::InlineFunction(), and UpdateCallGraphAfterInlining().
const_iterator llvm::CallGraphNode::begin | ( | ) | const [inline] |
Definition at line 186 of file CallGraph.h.
iterator llvm::CallGraphNode::begin | ( | ) | [inline] |
Definition at line 184 of file CallGraph.h.
Referenced by llvm::GraphTraits< const CallGraphNode * >::child_begin(), llvm::GraphTraits< CallGraphNode * >::child_begin(), InlineCallIfPossible(), print(), and UpdateCallGraphAfterInlining().
void CallGraphNode::dump | ( | ) | const |
dump - Print out this call graph node.
Definition at line 277 of file CallGraph.cpp.
References print().
const_iterator llvm::CallGraphNode::end | ( | ) | const [inline] |
Definition at line 187 of file CallGraph.h.
iterator llvm::CallGraphNode::end | ( | ) | [inline] |
Definition at line 185 of file CallGraph.h.
Referenced by llvm::GraphTraits< const CallGraphNode * >::child_end(), llvm::GraphTraits< CallGraphNode * >::child_end(), InlineCallIfPossible(), print(), and UpdateCallGraphAfterInlining().
Function* llvm::CallGraphNode::getFunction | ( | ) | const [inline] |
Definition at line 182 of file CallGraph.h.
Referenced by print(), and llvm::CallGraph::removeFunctionFromModule().
CallGraphNode* llvm::CallGraphNode::operator[] | ( | unsigned | i | ) | const [inline] |
Definition at line 192 of file CallGraph.h.
void CallGraphNode::print | ( | std::ostream & | OS | ) | const |
Definition at line 263 of file CallGraph.cpp.
References begin(), E, end(), and getFunction().
Referenced by dump().
void llvm::CallGraphNode::removeAllCalledFunctions | ( | ) | [inline] |
removeAllCalledFunctions - As the name implies, this removes all edges from this CallGraphNode to any functions it calls.
Definition at line 206 of file CallGraph.h.
void CallGraphNode::removeAnyCallEdgeTo | ( | CallGraphNode * | Callee | ) |
removeAnyCallEdgeTo - This method removes any call edges from this node to the specified callee function. This takes more time to execute than removeCallEdgeTo, so it should not be used unless necessary.
Definition at line 292 of file CallGraph.cpp.
Referenced by llvm::Inliner::doFinalization().
void CallGraphNode::removeCallEdgeTo | ( | CallGraphNode * | Callee | ) |
removeCallEdgeTo - This method removes a *single* edge to the specified callee function. Note that this method takes linear time, so it should be used sparingly.
Definition at line 279 of file CallGraph.cpp.
Referenced by InlineCallIfPossible(), and UpdateCallGraphAfterInlining().
unsigned llvm::CallGraphNode::size | ( | ) | const [inline] |
Definition at line 188 of file CallGraph.h.
friend class CallGraph [friend] |
Definition at line 226 of file CallGraph.h.