aboutsummaryrefslogtreecommitdiff
path: root/include/llvm/Analysis/DataStructure.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-10-21 19:47:18 +0000
committerChris Lattner <sabre@nondot.org>2002-10-21 19:47:18 +0000
commit198be22cec33455127f151a23a7b68e41de49db9 (patch)
treeaf3a8a2bf5dd55f5570ec9e091c2715444b7ada1 /include/llvm/Analysis/DataStructure.h
parenteff0da9d33b0067044638b9e53edf462a96e6eab (diff)
- Add "ResolvingCaller" to the CallSite record. This keeps track of which
function was finally able to resolve the function call. Adding this allows the TD pass to actually work right! - Temporarily disable dead node pruning. This will be reenabled soon. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4252 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/DataStructure.h')
-rw-r--r--include/llvm/Analysis/DataStructure.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/include/llvm/Analysis/DataStructure.h b/include/llvm/Analysis/DataStructure.h
index 2dc4ce4d1e..d44732a486 100644
--- a/include/llvm/Analysis/DataStructure.h
+++ b/include/llvm/Analysis/DataStructure.h
@@ -11,6 +11,7 @@
class Type;
class DSGraph;
+class DSNode;
class DSNodeHandle;
class DSCallSite;
class LocalDataStructures; // A collection of local graphs for a program
@@ -108,6 +109,15 @@ private:
class TDDataStructures : public Pass {
// DSInfo, one graph for each function
std::map<const Function*, DSGraph*> DSInfo;
+
+ // Each graph in DSInfo is based on a graph in the BUDS object. The BUMaps
+ // member keeps the mappings from the BU graphs to the TD graphs as they are
+ // calculated by calculateGraph. This information is used to properly
+ // implement resolving of call sites, where the call sites in the BUGraph are
+ // in terms of the caller function's graph in the BUGraph.
+ //
+ typedef std::map<const DSNode*, DSNodeHandle> BUNodeMapTy;
+ std::map<const Function*, BUNodeMapTy> BUMaps;
public:
~TDDataStructures() { releaseMemory(); }
@@ -134,8 +144,7 @@ public:
private:
DSGraph &calculateGraph(Function &F);
- void ResolveCallSite(DSGraph &Graph,
- const DSCallSite &CallSite);
+ void ResolveCallSite(DSGraph &Graph, const DSCallSite &CallSite);
};
#if 0