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_ARM | 5 #if V8_TARGET_ARCH_ARM |
6 | 6 |
7 #include "src/codegen.h" | 7 #include "src/codegen.h" |
8 #include "src/debug/debug.h" | 8 #include "src/debug/debug.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 1018 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1029 | 1029 |
1030 // Check function data field is actually a BytecodeArray object. | 1030 // Check function data field is actually a BytecodeArray object. |
1031 if (FLAG_debug_code) { | 1031 if (FLAG_debug_code) { |
1032 __ SmiTst(kInterpreterBytecodeArrayRegister); | 1032 __ SmiTst(kInterpreterBytecodeArrayRegister); |
1033 __ Assert(ne, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); | 1033 __ Assert(ne, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); |
1034 __ CompareObjectType(kInterpreterBytecodeArrayRegister, r0, no_reg, | 1034 __ CompareObjectType(kInterpreterBytecodeArrayRegister, r0, no_reg, |
1035 BYTECODE_ARRAY_TYPE); | 1035 BYTECODE_ARRAY_TYPE); |
1036 __ Assert(eq, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); | 1036 __ Assert(eq, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); |
1037 } | 1037 } |
1038 | 1038 |
| 1039 // Reset code age. |
| 1040 __ mov(r9, Operand(BytecodeArray::kNoAgeBytecodeAge)); |
| 1041 __ strb(r9, FieldMemOperand(kInterpreterBytecodeArrayRegister, |
| 1042 BytecodeArray::kBytecodeAgeOffset)); |
| 1043 |
1039 // Load the initial bytecode offset. | 1044 // Load the initial bytecode offset. |
1040 __ mov(kInterpreterBytecodeOffsetRegister, | 1045 __ mov(kInterpreterBytecodeOffsetRegister, |
1041 Operand(BytecodeArray::kHeaderSize - kHeapObjectTag)); | 1046 Operand(BytecodeArray::kHeaderSize - kHeapObjectTag)); |
1042 | 1047 |
1043 // Push new.target, bytecode array and Smi tagged bytecode array offset. | 1048 // Push new.target, bytecode array and Smi tagged bytecode array offset. |
1044 __ SmiTag(r0, kInterpreterBytecodeOffsetRegister); | 1049 __ SmiTag(r0, kInterpreterBytecodeOffsetRegister); |
1045 __ Push(r3, kInterpreterBytecodeArrayRegister, r0); | 1050 __ Push(r3, kInterpreterBytecodeArrayRegister, r0); |
1046 | 1051 |
1047 // Allocate the local and temporary register file on the stack. | 1052 // Allocate the local and temporary register file on the stack. |
1048 { | 1053 { |
(...skipping 1839 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2888 __ bkpt(0); | 2893 __ bkpt(0); |
2889 } | 2894 } |
2890 } | 2895 } |
2891 | 2896 |
2892 #undef __ | 2897 #undef __ |
2893 | 2898 |
2894 } // namespace internal | 2899 } // namespace internal |
2895 } // namespace v8 | 2900 } // namespace v8 |
2896 | 2901 |
2897 #endif // V8_TARGET_ARCH_ARM | 2902 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |