Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(981)

Unified Diff: src/hydrogen.cc

Issue 1183683004: [crankshaft] Fix wrong bailout points in for-in loop body. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Test case. Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-crbug-500435.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 12decb0a231487f226794b0598cb34f087baf229..945bf11d5adaf33555fd9a6c22186c46ec0e5301 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -5210,13 +5210,16 @@ void HOptimizedGraphBuilder::BuildForInBody(ForInStatement* stmt,
Runtime::FunctionId function_id = Runtime::kForInFilter;
key = Add<HCallRuntime>(isolate()->factory()->empty_string(),
Runtime::FunctionForId(function_id), 2);
+ Push(key);
+ Add<HSimulate>(stmt->FilterId());
+ key = Pop();
Bind(each_var, key);
- Add<HSimulate>(stmt->AssignmentId());
IfBuilder if_undefined(this);
if_undefined.If<HCompareObjectEqAndBranch>(key,
graph()->GetConstantUndefined());
if_undefined.ThenDeopt(Deoptimizer::kUndefined);
if_undefined.End();
+ Add<HSimulate>(stmt->AssignmentId());
}
BreakAndContinueInfo break_info(stmt, scope(), 5);
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-crbug-500435.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698