| 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 984 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 995 // the frame (that is done below). | 995 // the frame (that is done below). |
| 996 FrameScope frame_scope(masm, StackFrame::MANUAL); | 996 FrameScope frame_scope(masm, StackFrame::MANUAL); |
| 997 __ PushStandardFrame(r1); | 997 __ PushStandardFrame(r1); |
| 998 | 998 |
| 999 // Get the bytecode array from the function object (or from the DebugInfo if | 999 // Get the bytecode array from the function object (or from the DebugInfo if |
| 1000 // it is present) and load it into kInterpreterBytecodeArrayRegister. | 1000 // it is present) and load it into kInterpreterBytecodeArrayRegister. |
| 1001 __ ldr(r0, FieldMemOperand(r1, JSFunction::kSharedFunctionInfoOffset)); | 1001 __ ldr(r0, FieldMemOperand(r1, JSFunction::kSharedFunctionInfoOffset)); |
| 1002 Register debug_info = kInterpreterBytecodeArrayRegister; | 1002 Register debug_info = kInterpreterBytecodeArrayRegister; |
| 1003 DCHECK(!debug_info.is(r0)); | 1003 DCHECK(!debug_info.is(r0)); |
| 1004 __ ldr(debug_info, FieldMemOperand(r0, SharedFunctionInfo::kDebugInfoOffset)); | 1004 __ ldr(debug_info, FieldMemOperand(r0, SharedFunctionInfo::kDebugInfoOffset)); |
| 1005 __ cmp(debug_info, Operand(DebugInfo::uninitialized())); | 1005 __ SmiTst(debug_info); |
| 1006 // Load original bytecode array or the debug copy. | 1006 // Load original bytecode array or the debug copy. |
| 1007 __ ldr(kInterpreterBytecodeArrayRegister, | 1007 __ ldr(kInterpreterBytecodeArrayRegister, |
| 1008 FieldMemOperand(r0, SharedFunctionInfo::kFunctionDataOffset), eq); | 1008 FieldMemOperand(r0, SharedFunctionInfo::kFunctionDataOffset), eq); |
| 1009 __ ldr(kInterpreterBytecodeArrayRegister, | 1009 __ ldr(kInterpreterBytecodeArrayRegister, |
| 1010 FieldMemOperand(debug_info, DebugInfo::kDebugBytecodeArrayIndex), ne); | 1010 FieldMemOperand(debug_info, DebugInfo::kDebugBytecodeArrayIndex), ne); |
| 1011 | 1011 |
| 1012 // Check whether we should continue to use the interpreter. | 1012 // Check whether we should continue to use the interpreter. |
| 1013 Label switch_to_different_code_kind; | 1013 Label switch_to_different_code_kind; |
| 1014 __ ldr(r0, FieldMemOperand(r0, SharedFunctionInfo::kCodeOffset)); | 1014 __ ldr(r0, FieldMemOperand(r0, SharedFunctionInfo::kCodeOffset)); |
| 1015 __ cmp(r0, Operand(masm->CodeObject())); // Self-reference to this code. | 1015 __ cmp(r0, Operand(masm->CodeObject())); // Self-reference to this code. |
| (...skipping 2014 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3030 __ bkpt(0); | 3030 __ bkpt(0); |
| 3031 } | 3031 } |
| 3032 } | 3032 } |
| 3033 | 3033 |
| 3034 #undef __ | 3034 #undef __ |
| 3035 | 3035 |
| 3036 } // namespace internal | 3036 } // namespace internal |
| 3037 } // namespace v8 | 3037 } // namespace v8 |
| 3038 | 3038 |
| 3039 #endif // V8_TARGET_ARCH_ARM | 3039 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |