Index: src/full-codegen/x87/full-codegen-x87.cc |
diff --git a/src/full-codegen/x87/full-codegen-x87.cc b/src/full-codegen/x87/full-codegen-x87.cc |
index 277dcb3b9a93476e6b549e841f0c45e58f7fb432..60ad17f5b4041085cd334ff14ab1674d1ce50e0b 100644 |
--- a/src/full-codegen/x87/full-codegen-x87.cc |
+++ b/src/full-codegen/x87/full-codegen-x87.cc |
@@ -1067,7 +1067,6 @@ void FullCodeGenerator::VisitForInStatement(ForInStatement* stmt) { |
__ push(Immediate(Smi::FromInt(0))); // Initial index. |
// Generate code for doing the condition check. |
- PrepareForBailoutForId(stmt->BodyId(), NO_REGISTERS); |
__ bind(&loop); |
SetExpressionAsStatementPosition(stmt->each()); |
@@ -1117,6 +1116,8 @@ void FullCodeGenerator::VisitForInStatement(ForInStatement* stmt) { |
PrepareForBailoutForId(stmt->AssignmentId(), NO_REGISTERS); |
} |
+ // Both Crankshaft and Turbofan expect BodyId to be right before stmt->body(). |
+ PrepareForBailoutForId(stmt->BodyId(), NO_REGISTERS); |
// Generate code for the body of the loop. |
Visit(stmt->body()); |