OLD | NEW |
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/code-factory.h" | 7 #include "src/code-factory.h" |
8 #include "src/codegen.h" | 8 #include "src/codegen.h" |
9 #include "src/deoptimizer.h" | 9 #include "src/deoptimizer.h" |
10 #include "src/full-codegen/full-codegen.h" | 10 #include "src/full-codegen/full-codegen.h" |
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
556 Immediate(Smi::FromInt(1))); | 556 Immediate(Smi::FromInt(1))); |
557 | 557 |
558 // Check function data field is actually a BytecodeArray object. | 558 // Check function data field is actually a BytecodeArray object. |
559 if (FLAG_debug_code) { | 559 if (FLAG_debug_code) { |
560 __ AssertNotSmi(kInterpreterBytecodeArrayRegister); | 560 __ AssertNotSmi(kInterpreterBytecodeArrayRegister); |
561 __ CmpObjectType(kInterpreterBytecodeArrayRegister, BYTECODE_ARRAY_TYPE, | 561 __ CmpObjectType(kInterpreterBytecodeArrayRegister, BYTECODE_ARRAY_TYPE, |
562 eax); | 562 eax); |
563 __ Assert(equal, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); | 563 __ Assert(equal, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); |
564 } | 564 } |
565 | 565 |
| 566 // Reset code age. |
| 567 __ mov_b(FieldOperand(kInterpreterBytecodeArrayRegister, |
| 568 BytecodeArray::kBytecodeAgeOffset), |
| 569 Immediate(BytecodeArray::kNoAgeBytecodeAge)); |
| 570 |
566 // Push bytecode array. | 571 // Push bytecode array. |
567 __ push(kInterpreterBytecodeArrayRegister); | 572 __ push(kInterpreterBytecodeArrayRegister); |
568 // Push Smi tagged initial bytecode array offset. | 573 // Push Smi tagged initial bytecode array offset. |
569 __ push(Immediate(Smi::FromInt(BytecodeArray::kHeaderSize - kHeapObjectTag))); | 574 __ push(Immediate(Smi::FromInt(BytecodeArray::kHeaderSize - kHeapObjectTag))); |
570 | 575 |
571 // Allocate the local and temporary register file on the stack. | 576 // Allocate the local and temporary register file on the stack. |
572 { | 577 { |
573 // Load frame size from the BytecodeArray object. | 578 // Load frame size from the BytecodeArray object. |
574 __ mov(ebx, FieldOperand(kInterpreterBytecodeArrayRegister, | 579 __ mov(ebx, FieldOperand(kInterpreterBytecodeArrayRegister, |
575 BytecodeArray::kFrameSizeOffset)); | 580 BytecodeArray::kFrameSizeOffset)); |
(...skipping 2534 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3110 | 3115 |
3111 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) { | 3116 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) { |
3112 Generate_OnStackReplacementHelper(masm, true); | 3117 Generate_OnStackReplacementHelper(masm, true); |
3113 } | 3118 } |
3114 | 3119 |
3115 #undef __ | 3120 #undef __ |
3116 } // namespace internal | 3121 } // namespace internal |
3117 } // namespace v8 | 3122 } // namespace v8 |
3118 | 3123 |
3119 #endif // V8_TARGET_ARCH_IA32 | 3124 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |