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

Side by Side Diff: src/full-codegen/ia32/full-codegen-ia32.cc

Issue 1630523002: [turbofan] Switch JSForInPrepare to %ForInPrepare style. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_IA32 5 #if V8_TARGET_ARCH_IA32
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/code-factory.h" 8 #include "src/code-factory.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 1037 matching lines...) Expand 10 before | Expand all | Expand 10 after
1048 1048
1049 // No need for a write barrier, we are storing a Smi in the feedback vector. 1049 // No need for a write barrier, we are storing a Smi in the feedback vector.
1050 __ EmitLoadTypeFeedbackVector(ebx); 1050 __ EmitLoadTypeFeedbackVector(ebx);
1051 int vector_index = SmiFromSlot(slot)->value(); 1051 int vector_index = SmiFromSlot(slot)->value();
1052 __ mov(FieldOperand(ebx, FixedArray::OffsetOfElementAt(vector_index)), 1052 __ mov(FieldOperand(ebx, FixedArray::OffsetOfElementAt(vector_index)),
1053 Immediate(TypeFeedbackVector::MegamorphicSentinel(isolate()))); 1053 Immediate(TypeFeedbackVector::MegamorphicSentinel(isolate())));
1054 __ push(Immediate(Smi::FromInt(1))); // Smi(1) indicates slow check 1054 __ push(Immediate(Smi::FromInt(1))); // Smi(1) indicates slow check
1055 __ push(eax); // Array 1055 __ push(eax); // Array
1056 __ mov(eax, FieldOperand(eax, FixedArray::kLengthOffset)); 1056 __ mov(eax, FieldOperand(eax, FixedArray::kLengthOffset));
1057 __ push(eax); // Fixed array length (as smi). 1057 __ push(eax); // Fixed array length (as smi).
1058 PrepareForBailoutForId(stmt->PrepareId(), NO_REGISTERS);
1058 __ push(Immediate(Smi::FromInt(0))); // Initial index. 1059 __ push(Immediate(Smi::FromInt(0))); // Initial index.
1059 1060
1060 // Generate code for doing the condition check. 1061 // Generate code for doing the condition check.
1061 __ bind(&loop); 1062 __ bind(&loop);
1062 SetExpressionAsStatementPosition(stmt->each()); 1063 SetExpressionAsStatementPosition(stmt->each());
1063 1064
1064 __ mov(eax, Operand(esp, 0 * kPointerSize)); // Get the current index. 1065 __ mov(eax, Operand(esp, 0 * kPointerSize)); // Get the current index.
1065 __ cmp(eax, Operand(esp, 1 * kPointerSize)); // Compare to the array length. 1066 __ cmp(eax, Operand(esp, 1 * kPointerSize)); // Compare to the array length.
1066 __ j(above_equal, loop_statement.break_label()); 1067 __ j(above_equal, loop_statement.break_label());
1067 1068
(...skipping 3649 matching lines...) Expand 10 before | Expand all | Expand 10 after
4717 Assembler::target_address_at(call_target_address, 4718 Assembler::target_address_at(call_target_address,
4718 unoptimized_code)); 4719 unoptimized_code));
4719 return OSR_AFTER_STACK_CHECK; 4720 return OSR_AFTER_STACK_CHECK;
4720 } 4721 }
4721 4722
4722 4723
4723 } // namespace internal 4724 } // namespace internal
4724 } // namespace v8 4725 } // namespace v8
4725 4726
4726 #endif // V8_TARGET_ARCH_IA32 4727 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/full-codegen/arm64/full-codegen-arm64.cc ('k') | src/full-codegen/mips/full-codegen-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698