diff options
author | Vikram S. Adve <vadve@cs.uiuc.edu> | 2001-11-11 01:23:27 +0000 |
---|---|---|
committer | Vikram S. Adve <vadve@cs.uiuc.edu> | 2001-11-11 01:23:27 +0000 |
commit | 5b43af962bea1e1e4ca0c8306e60bfbb39e6caba (patch) | |
tree | 3898607f270908a3de5867b3540a7e20d5eb9cf6 /lib/CodeGen/InstrSched/SchedGraph.h | |
parent | 65480b75afbb856e91cf95d2a38bc784a2dc3d30 (diff) |
Only add true dep. edges from an earlier to a later instruction.
This wasn't a problem until we started putting copies for Phi values
that produced cycles in the SchedGraph!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1254 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/InstrSched/SchedGraph.h')
-rw-r--r-- | lib/CodeGen/InstrSched/SchedGraph.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/CodeGen/InstrSched/SchedGraph.h b/lib/CodeGen/InstrSched/SchedGraph.h index 6f6739b39b..dc5d0059e5 100644 --- a/lib/CodeGen/InstrSched/SchedGraph.h +++ b/lib/CodeGen/InstrSched/SchedGraph.h @@ -146,6 +146,7 @@ private: const MachineInstr* minstr; vector<SchedGraphEdge*> inEdges; vector<SchedGraphEdge*> outEdges; + int origIndexInBB; // original position of machine instr in BB int latency; public: @@ -166,6 +167,7 @@ public: unsigned int getNumInEdges () const { return inEdges.size(); } unsigned int getNumOutEdges () const { return outEdges.size(); } bool isDummyNode () const { return (minstr == NULL); } + int getOrigIndexInBB() const { return origIndexInBB; } // // Iterators @@ -203,6 +205,7 @@ private: /*ctor*/ SchedGraphNode (unsigned int _nodeId, const Instruction* _instr, const MachineInstr* _minstr, + int indexInBB, const TargetMachine& _target); /*dtor*/ ~SchedGraphNode (); }; @@ -303,8 +306,8 @@ private: // void buildGraph (const TargetMachine& target); - void buildNodesforVMInstr (const TargetMachine& target, - const Instruction* instr, + void buildNodesforBB (const TargetMachine& target, + const BasicBlock* bb, vector<SchedGraphNode*>& memNodeVec, RegToRefVecMap& regToRefVecMap, ValueToDefVecMap& valueToDefVecMap); |