diff options
author | Tanya Lattner <tonic@nondot.org> | 2004-11-28 23:36:15 +0000 |
---|---|---|
committer | Tanya Lattner <tonic@nondot.org> | 2004-11-28 23:36:15 +0000 |
commit | 28e5eabf65a7d5afddddbf5e90b0ed8c85140cd6 (patch) | |
tree | c2b31ebbc6217e9e441ab0f1cfbc46d980a79306 /lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h | |
parent | b2e4cd645a3392501d41ad55c0d7753e75efe9ac (diff) |
Fixed bug where instructions in the kernel were not ordered right to preserve dependencies in a cycle.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18314 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h')
-rw-r--r-- | lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h b/lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h index baa6373510..36b76324cb 100644 --- a/lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h +++ b/lib/Target/SparcV9/ModuloScheduling/MSchedGraph.h @@ -58,15 +58,17 @@ namespace llvm { const MachineInstr* Inst; //Machine Instruction MSchedGraph* Parent; //Graph this node belongs to + unsigned index; //Index in BB unsigned latency; //Latency of Instruction bool isBranchInstr; //Is this node the branch instr or not + std::vector<MSchedGraphNode*> Predecessors; //Predecessor Nodes std::vector<MSchedGraphEdge> Successors; public: MSchedGraphNode(const MachineInstr *inst, MSchedGraph *graph, - unsigned late=0, bool isBranch=false); + unsigned index, unsigned late=0, bool isBranch=false); //Iterators typedef std::vector<MSchedGraphNode*>::iterator pred_iterator; @@ -102,7 +104,7 @@ namespace llvm { bool hasSuccessors() { return (Successors.size() > 0); } unsigned getLatency() { return latency; } unsigned getLatency() const { return latency; } - + unsigned getIndex() { return index; } MSchedGraphEdge getInEdge(MSchedGraphNode *pred); unsigned getInEdgeNum(MSchedGraphNode *pred); |