| Index: src/crankshaft/hydrogen.cc
|
| diff --git a/src/crankshaft/hydrogen.cc b/src/crankshaft/hydrogen.cc
|
| index 7d16c4813e0a855ed62be08e2cd143eb0b3550c2..ae68d7fb24971f872b967a14fe96090d3225e140 100644
|
| --- a/src/crankshaft/hydrogen.cc
|
| +++ b/src/crankshaft/hydrogen.cc
|
| @@ -5402,10 +5402,12 @@ void HOptimizedGraphBuilder::BuildForInBody(ForInStatement* stmt,
|
| }
|
| set_current_block(if_slow);
|
| {
|
| - // Check if key is still valid for enumerable.
|
| - Add<HPushArguments>(enumerable, key);
|
| - Runtime::FunctionId function_id = Runtime::kForInFilter;
|
| - Push(Add<HCallRuntime>(Runtime::FunctionForId(function_id), 2));
|
| + ForInFilterStub stub(isolate());
|
| + HValue* values[] = {context(), key, enumerable};
|
| + HConstant* stub_value = Add<HConstant>(stub.GetCode());
|
| + Push(Add<HCallWithDescriptor>(stub_value, 0,
|
| + stub.GetCallInterfaceDescriptor(),
|
| + ArrayVector(values)));
|
| Add<HSimulate>(stmt->FilterId());
|
| FinishCurrentBlock(New<HCompareObjectEqAndBranch>(
|
| Top(), graph()->GetConstantUndefined(), if_slow_skip, if_slow_pass));
|
|
|