From: Chris Lattner Date: Sat, 14 Jan 2006 20:01:50 +0000 (+0000) Subject: Add CallGraph::getOrInsertFunction, to allow clients to update the callgraph X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=56151dad2ea6bd57c516fcb24cf175cfeab3e602;p=oota-llvm.git Add CallGraph::getOrInsertFunction, to allow clients to update the callgraph when they change the program git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25316 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/Analysis/CallGraph.h b/include/llvm/Analysis/CallGraph.h index e477be34f8e..734306015c0 100644 --- a/include/llvm/Analysis/CallGraph.h +++ b/include/llvm/Analysis/CallGraph.h @@ -132,6 +132,11 @@ public: /// old code over). void changeFunction(Function *OldF, Function *NewF); + /// getOrInsertFunction - This method is identical to calling operator[], but + /// it will insert a new CallGraphNode for the specified function if one does + /// not already exist. + CallGraphNode *getOrInsertFunction(const Function *F); + //===--------------------------------------------------------------------- // Pass infrastructure interface glue code... //