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_MIPS | 5 #if V8_TARGET_ARCH_MIPS |
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 987 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
998 FrameScope frame_scope(masm, StackFrame::MANUAL); | 998 FrameScope frame_scope(masm, StackFrame::MANUAL); |
999 __ PushStandardFrame(a1); | 999 __ PushStandardFrame(a1); |
1000 | 1000 |
1001 // Get the bytecode array from the function object (or from the DebugInfo if | 1001 // Get the bytecode array from the function object (or from the DebugInfo if |
1002 // it is present) and load it into kInterpreterBytecodeArrayRegister. | 1002 // it is present) and load it into kInterpreterBytecodeArrayRegister. |
1003 __ lw(a0, FieldMemOperand(a1, JSFunction::kSharedFunctionInfoOffset)); | 1003 __ lw(a0, FieldMemOperand(a1, JSFunction::kSharedFunctionInfoOffset)); |
1004 Label load_debug_bytecode_array, bytecode_array_loaded; | 1004 Label load_debug_bytecode_array, bytecode_array_loaded; |
1005 Register debug_info = kInterpreterBytecodeArrayRegister; | 1005 Register debug_info = kInterpreterBytecodeArrayRegister; |
1006 DCHECK(!debug_info.is(a0)); | 1006 DCHECK(!debug_info.is(a0)); |
1007 __ lw(debug_info, FieldMemOperand(a0, SharedFunctionInfo::kDebugInfoOffset)); | 1007 __ lw(debug_info, FieldMemOperand(a0, SharedFunctionInfo::kDebugInfoOffset)); |
1008 __ Branch(&load_debug_bytecode_array, ne, debug_info, | 1008 __ JumpIfNotSmi(debug_info, &load_debug_bytecode_array); |
1009 Operand(DebugInfo::uninitialized())); | |
1010 __ lw(kInterpreterBytecodeArrayRegister, | 1009 __ lw(kInterpreterBytecodeArrayRegister, |
1011 FieldMemOperand(a0, SharedFunctionInfo::kFunctionDataOffset)); | 1010 FieldMemOperand(a0, SharedFunctionInfo::kFunctionDataOffset)); |
1012 __ bind(&bytecode_array_loaded); | 1011 __ bind(&bytecode_array_loaded); |
1013 | 1012 |
1014 // Check whether we should continue to use the interpreter. | 1013 // Check whether we should continue to use the interpreter. |
1015 Label switch_to_different_code_kind; | 1014 Label switch_to_different_code_kind; |
1016 __ lw(a0, FieldMemOperand(a0, SharedFunctionInfo::kCodeOffset)); | 1015 __ lw(a0, FieldMemOperand(a0, SharedFunctionInfo::kCodeOffset)); |
1017 __ Branch(&switch_to_different_code_kind, ne, a0, | 1016 __ Branch(&switch_to_different_code_kind, ne, a0, |
1018 Operand(masm->CodeObject())); // Self-reference to this code. | 1017 Operand(masm->CodeObject())); // Self-reference to this code. |
1019 | 1018 |
(...skipping 2085 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3105 __ break_(0xCC); | 3104 __ break_(0xCC); |
3106 } | 3105 } |
3107 } | 3106 } |
3108 | 3107 |
3109 #undef __ | 3108 #undef __ |
3110 | 3109 |
3111 } // namespace internal | 3110 } // namespace internal |
3112 } // namespace v8 | 3111 } // namespace v8 |
3113 | 3112 |
3114 #endif // V8_TARGET_ARCH_MIPS | 3113 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |