Index: src/hydrogen-bce.cc |
diff --git a/src/hydrogen-bce.cc b/src/hydrogen-bce.cc |
index 2514f7d259de8d63095bc416b5219762f8cca145..e1a28471273f75274a85056b2c78ff06dba8cf10 100644 |
--- a/src/hydrogen-bce.cc |
+++ b/src/hydrogen-bce.cc |
@@ -375,7 +375,8 @@ BoundsCheckBbData* HBoundsCheckEliminationPhase::PreProcessBlock( |
check->DeleteAndReplaceWith(check->ActualValue()); |
} else if (data->BasicBlock() == bb) { |
data->CoverCheck(check, offset); |
- } else { |
+ } else if (graph()->use_optimistic_licm() || |
+ bb->IsLoopSuccessorDominator()) { |
int32_t new_lower_offset = offset < data->LowerOffset() |
? offset |
: data->LowerOffset(); |