diff options
author | Evan Cheng <evan.cheng@apple.com> | 2006-08-01 08:20:41 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2006-08-01 08:20:41 +0000 |
commit | e6f35d8a5cc92d776cf460200e2b815e8c301b14 (patch) | |
tree | e1794f42cf59c7c39c893a43f716dd597ba8ed03 /include | |
parent | db3cc3d7d663a8dc2063d1bb581851e5e66f269d (diff) | |
download | external_llvm-e6f35d8a5cc92d776cf460200e2b815e8c301b14.zip external_llvm-e6f35d8a5cc92d776cf460200e2b815e8c301b14.tar.gz external_llvm-e6f35d8a5cc92d776cf460200e2b815e8c301b14.tar.bz2 |
Added AssignTopologicalOrder() to assign each node an unique id based on their topological order.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29431 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/CodeGen/SelectionDAG.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/llvm/CodeGen/SelectionDAG.h b/include/llvm/CodeGen/SelectionDAG.h index 91d2800..b7dda01 100644 --- a/include/llvm/CodeGen/SelectionDAG.h +++ b/include/llvm/CodeGen/SelectionDAG.h @@ -422,10 +422,15 @@ public: /// have no referrers. void DeleteNode(SDNode *N); - /// AssignNodeIds - Assign a unique node id for each node in the DAG. It - /// returns the maximum id. + /// AssignNodeIds - Assign a unique node id for each node in the DAG based on + /// their allnodes order. It returns the maximum id. unsigned AssignNodeIds(); + /// AssignTopologicalOrder - Assign a unique node id for each node in the DAG + /// based on their topological order. It returns a vector of the SDNodes* in + /// assigned order. + std::vector<SDNode*> AssignTopologicalOrder(); + void dump() const; /// InsertISelMapEntry - A helper function to insert a key / element pair |