diff options
author | Tanya Lattner <tonic@nondot.org> | 2003-08-28 15:31:28 +0000 |
---|---|---|
committer | Tanya Lattner <tonic@nondot.org> | 2003-08-28 15:31:28 +0000 |
commit | 44a1aff9255202f8085b472966cb13c74b8d58b4 (patch) | |
tree | 9365a8658d1802a01996214ec9bbbde7fd3fe8b3 /llvm | |
parent | 89860151b99408191c50fca0c72b6a0bd0380180 (diff) | |
download | bcm5719-llvm-44a1aff9255202f8085b472966cb13c74b8d58b4.tar.gz bcm5719-llvm-44a1aff9255202f8085b472966cb13c74b8d58b4.zip |
Moved index in BB to common graph class.
llvm-svn: 8175
Diffstat (limited to 'llvm')
-rw-r--r-- | llvm/include/llvm/CodeGen/SchedGraphCommon.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/include/llvm/CodeGen/SchedGraphCommon.h b/llvm/include/llvm/CodeGen/SchedGraphCommon.h index fc2b1bac6f3..46e49e14ea1 100644 --- a/llvm/include/llvm/CodeGen/SchedGraphCommon.h +++ b/llvm/include/llvm/CodeGen/SchedGraphCommon.h @@ -29,6 +29,7 @@ protected: std::vector<SchedGraphEdge*> inEdges; std::vector<SchedGraphEdge*> outEdges; int latency; + int origIndexInBB; // original position of instr in BB public: typedef std::vector<SchedGraphEdge*>::iterator iterator; @@ -41,7 +42,7 @@ public: int getLatency() const { return latency; } unsigned getNumInEdges() const { return inEdges.size(); } unsigned getNumOutEdges() const { return outEdges.size(); } - + int getOrigIndexInBB() const { return origIndexInBB; } // Iterators iterator beginInEdges() { return inEdges.begin(); } @@ -68,7 +69,8 @@ protected: // disable default constructor and provide a ctor for single-block graphs SchedGraphNodeCommon(); // DO NOT IMPLEMENT - inline SchedGraphNodeCommon(unsigned Id) : ID(Id), latency(0) {} + inline SchedGraphNodeCommon(unsigned Id, int index) : ID(Id), latency(0), + origIndexInBB(index) {} virtual ~SchedGraphNodeCommon(); //Functions to add and remove edges |