diff options
Diffstat (limited to 'compiler/sea_ir/instruction_nodes.h')
-rw-r--r-- | compiler/sea_ir/instruction_nodes.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/compiler/sea_ir/instruction_nodes.h b/compiler/sea_ir/instruction_nodes.h index 6f9bdddf77..1b81e9add3 100644 --- a/compiler/sea_ir/instruction_nodes.h +++ b/compiler/sea_ir/instruction_nodes.h @@ -61,7 +61,7 @@ class InstructionNode: public SeaNode { } // Returns the ordered set of Instructions that define the input operands of this instruction. // Precondition: SeaGraph.ConvertToSSA(). - std::vector<InstructionNode*> GetSSAUses() { + std::vector<InstructionNode*> GetSSAProducers() { std::vector<int> uses = GetUses(); std::vector<InstructionNode*> ssa_uses; for (std::vector<int>::const_iterator cit = uses.begin(); cit != uses.end(); cit++) { @@ -70,6 +70,10 @@ class InstructionNode: public SeaNode { return ssa_uses; } + std::vector<InstructionNode*> GetSSAConsumers() { + return used_in_; + } + virtual void AddSSAUse(InstructionNode* use) { used_in_.push_back(use); } |