| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/globals.h" | 5 #include "vm/globals.h" |
| 6 #if defined(TARGET_ARCH_ARM) | 6 #if defined(TARGET_ARCH_ARM) |
| 7 | 7 |
| 8 #include "vm/assembler.h" | 8 #include "vm/assembler.h" |
| 9 #include "vm/code_generator.h" | 9 #include "vm/code_generator.h" |
| 10 #include "vm/cpu.h" | 10 #include "vm/cpu.h" |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 void StubCode::GenerateCallToRuntimeStub(Assembler* assembler) { | 39 void StubCode::GenerateCallToRuntimeStub(Assembler* assembler) { |
| 40 const intptr_t isolate_offset = NativeArguments::isolate_offset(); | 40 const intptr_t isolate_offset = NativeArguments::isolate_offset(); |
| 41 const intptr_t argc_tag_offset = NativeArguments::argc_tag_offset(); | 41 const intptr_t argc_tag_offset = NativeArguments::argc_tag_offset(); |
| 42 const intptr_t argv_offset = NativeArguments::argv_offset(); | 42 const intptr_t argv_offset = NativeArguments::argv_offset(); |
| 43 const intptr_t retval_offset = NativeArguments::retval_offset(); | 43 const intptr_t retval_offset = NativeArguments::retval_offset(); |
| 44 const intptr_t exitframe_last_param_slot_from_fp = 2; | 44 const intptr_t exitframe_last_param_slot_from_fp = 2; |
| 45 | 45 |
| 46 __ mov(IP, Operand(0)); | 46 __ mov(IP, Operand(0)); |
| 47 __ Push(IP); // Push 0 for the PC marker. | 47 __ Push(IP); // Push 0 for the PC marker. |
| 48 __ EnterFrame((1 << FP) | (1 << LR), 0); | 48 __ EnterFrame((1 << FP) | (1 << LR), 0); |
| 49 __ SmiUntag(R4); |
| 49 | 50 |
| 50 // Load current Isolate pointer from Context structure into R0. | 51 // Load current Isolate pointer from Context structure into R0. |
| 51 __ ldr(R0, FieldAddress(CTX, Context::isolate_offset())); | 52 __ ldr(R0, FieldAddress(CTX, Context::isolate_offset())); |
| 52 | 53 |
| 53 // Save exit frame information to enable stack walking as we are about | 54 // Save exit frame information to enable stack walking as we are about |
| 54 // to transition to Dart VM C++ code. | 55 // to transition to Dart VM C++ code. |
| 55 __ StoreToOffset(kWord, SP, R0, Isolate::top_exit_frame_info_offset()); | 56 __ StoreToOffset(kWord, SP, R0, Isolate::top_exit_frame_info_offset()); |
| 56 | 57 |
| 57 // Save current Context pointer into Isolate structure. | 58 // Save current Context pointer into Isolate structure. |
| 58 __ StoreToOffset(kWord, CTX, R0, Isolate::top_context_offset()); | 59 __ StoreToOffset(kWord, CTX, R0, Isolate::top_context_offset()); |
| (...skipping 1771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1830 const Register right = R0; | 1831 const Register right = R0; |
| 1831 __ ldr(left, Address(SP, 1 * kWordSize)); | 1832 __ ldr(left, Address(SP, 1 * kWordSize)); |
| 1832 __ ldr(right, Address(SP, 0 * kWordSize)); | 1833 __ ldr(right, Address(SP, 0 * kWordSize)); |
| 1833 GenerateIdenticalWithNumberCheckStub(assembler, left, right, temp); | 1834 GenerateIdenticalWithNumberCheckStub(assembler, left, right, temp); |
| 1834 __ Ret(); | 1835 __ Ret(); |
| 1835 } | 1836 } |
| 1836 | 1837 |
| 1837 } // namespace dart | 1838 } // namespace dart |
| 1838 | 1839 |
| 1839 #endif // defined TARGET_ARCH_ARM | 1840 #endif // defined TARGET_ARCH_ARM |
| OLD | NEW |