Switch the Nodes list from being an std::vector<DSNode*> to an ilist<DSNode>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11173 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner
2004-02-08 00:53:26 +00:00
parent 2cca3008e8
commit 28897e1784
5 changed files with 83 additions and 27 deletions

View File

@@ -92,7 +92,7 @@ struct DSGraph {
typedef DSScalarMap ScalarMapTy;
typedef hash_map<Function*, DSNodeHandle> ReturnNodesTy;
typedef hash_set<GlobalValue*> GlobalSetTy;
typedef std::vector<DSNode*> NodeListTy;
typedef ilist<DSNode> NodeListTy;
/// NodeMapTy - This data type is used when cloning one graph into another to
/// keep track of the correspondence between the nodes in the old and new
@@ -171,9 +171,9 @@ public:
/// getNodes - Get a vector of all the nodes in the graph
///
typedef NodeListTy::const_iterator node_iterator;
node_iterator node_begin() const { return Nodes.begin(); }
node_iterator node_end() const { return Nodes.end(); }
typedef NodeListTy::compat_iterator node_iterator;
node_iterator node_begin() const { return Nodes.compat_begin(); }
node_iterator node_end() const { return Nodes.compat_end(); }
/// getFunctionNames - Return a space separated list of the name of the
/// functions in this graph (if any)