Index: src/crankshaft/hydrogen.cc |
diff --git a/src/crankshaft/hydrogen.cc b/src/crankshaft/hydrogen.cc |
index 2e0695dfdf8b4902ef1366226b0f9c5282403036..4cdf74782e26fe4743be78491bcb9840e34b8ad1 100644 |
--- a/src/crankshaft/hydrogen.cc |
+++ b/src/crankshaft/hydrogen.cc |
@@ -7452,6 +7452,9 @@ bool HOptimizedGraphBuilder::TryArgumentsAccess(Property* expr) { |
result = New<HConstant>(argument_count); |
} |
} else { |
+ // We need to take into account the KEYED_LOAD_IC feedback to guard the |
+ // HBoundsCheck instructions below. |
+ if (!expr->IsMonomorphic()) return false; |
CHECK_ALIVE_OR_RETURN(VisitForValue(expr->obj(), ARGUMENTS_ALLOWED), true); |
CHECK_ALIVE_OR_RETURN(VisitForValue(expr->key()), true); |
HValue* key = Pop(); |