| Index: src/hydrogen.cc
|
| diff --git a/src/hydrogen.cc b/src/hydrogen.cc
|
| index 3fb867bde3d5ed6403c6ee474a2e5dca71469d1c..bc898050f00c7ad702fac60bb3c9c91f3508bf11 100644
|
| --- a/src/hydrogen.cc
|
| +++ b/src/hydrogen.cc
|
| @@ -302,6 +302,12 @@ bool HBasicBlock::Dominates(HBasicBlock* other) const {
|
| }
|
|
|
|
|
| +bool HBasicBlock::EqualToOrDominates(HBasicBlock* other) const {
|
| + if (this == other) return true;
|
| + return Dominates(other);
|
| +}
|
| +
|
| +
|
| int HBasicBlock::LoopNestingDepth() const {
|
| const HBasicBlock* current = this;
|
| int result = (current->IsLoopHeader()) ? 1 : 0;
|
| @@ -3915,7 +3921,13 @@ void HGraph::RestoreActualValues() {
|
|
|
| for (HInstructionIterator it(block); !it.Done(); it.Advance()) {
|
| HInstruction* instruction = it.Current();
|
| - if (instruction->ActualValue() != instruction) {
|
| + if (instruction->CheckFlag(HValue::kIsDead)) {
|
| + // The instruction was marked as deleted but left in the graph
|
| + // as a control flow dependency point for subsequent
|
| + // instructions.
|
| + instruction->DeleteAndReplaceWith(instruction->ActualValue());
|
| +
|
| + } else if (instruction->ActualValue() != instruction) {
|
| ASSERT(instruction->IsInformativeDefinition());
|
| if (instruction->IsPurelyInformativeDefinition()) {
|
| instruction->DeleteAndReplaceWith(instruction->RedefinedOperand());
|
|
|