Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(572)

Side by Side Diff: runtime/vm/stub_code_mips.cc

Issue 1387643002: Move vm_tags from isolate to thread, since we may have multiple threads in same isolate (GC, backgr… (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: More comment cleanups Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/stub_code_ia32.cc ('k') | runtime/vm/stub_code_x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_MIPS) 6 #if defined(TARGET_ARCH_MIPS)
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/compiler.h" 10 #include "vm/compiler.h"
(...skipping 28 matching lines...) Expand all
39 void StubCode::GenerateCallToRuntimeStub(Assembler* assembler) { 39 void StubCode::GenerateCallToRuntimeStub(Assembler* assembler) {
40 const intptr_t thread_offset = NativeArguments::thread_offset(); 40 const intptr_t thread_offset = NativeArguments::thread_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 44
45 __ SetPrologueOffset(); 45 __ SetPrologueOffset();
46 __ Comment("CallToRuntimeStub"); 46 __ Comment("CallToRuntimeStub");
47 __ EnterStubFrame(); 47 __ EnterStubFrame();
48 48
49 COMPILE_ASSERT((kAbiPreservedCpuRegs & (1 << S2)) != 0);
50 __ LoadIsolate(S2);
51
52 // Save exit frame information to enable stack walking as we are about 49 // Save exit frame information to enable stack walking as we are about
53 // to transition to Dart VM C++ code. 50 // to transition to Dart VM C++ code.
54 __ sw(FP, Address(THR, Thread::top_exit_frame_info_offset())); 51 __ sw(FP, Address(THR, Thread::top_exit_frame_info_offset()));
55 52
56 #if defined(DEBUG) 53 #if defined(DEBUG)
57 { Label ok; 54 { Label ok;
58 // Check that we are always entering from Dart code. 55 // Check that we are always entering from Dart code.
59 __ lw(T0, Address(S2, Isolate::vm_tag_offset())); 56 __ lw(T0, Assembler::VMTagAddress());
60 __ BranchEqual(T0, Immediate(VMTag::kDartTagId), &ok); 57 __ BranchEqual(T0, Immediate(VMTag::kDartTagId), &ok);
61 __ Stop("Not coming from Dart code."); 58 __ Stop("Not coming from Dart code.");
62 __ Bind(&ok); 59 __ Bind(&ok);
63 } 60 }
64 #endif 61 #endif
65 62
66 // Mark that the isolate is executing VM code. 63 // Mark that the thread is executing VM code.
67 __ sw(S5, Address(S2, Isolate::vm_tag_offset())); 64 __ sw(S5, Assembler::VMTagAddress());
68 65
69 // Reserve space for arguments and align frame before entering C++ world. 66 // Reserve space for arguments and align frame before entering C++ world.
70 // NativeArguments are passed in registers. 67 // NativeArguments are passed in registers.
71 ASSERT(sizeof(NativeArguments) == 4 * kWordSize); 68 ASSERT(sizeof(NativeArguments) == 4 * kWordSize);
72 __ ReserveAlignedFrameSpace(4 * kWordSize); // Reserve space for arguments. 69 __ ReserveAlignedFrameSpace(4 * kWordSize); // Reserve space for arguments.
73 70
74 // Pass NativeArguments structure by value and call runtime. 71 // Pass NativeArguments structure by value and call runtime.
75 // Registers A0, A1, A2, and A3 are used. 72 // Registers A0, A1, A2, and A3 are used.
76 73
77 ASSERT(thread_offset == 0 * kWordSize); 74 ASSERT(thread_offset == 0 * kWordSize);
(...skipping 16 matching lines...) Expand all
94 // We defensively always jalr through T9 because it is sometimes required by 91 // We defensively always jalr through T9 because it is sometimes required by
95 // the MIPS ABI. 92 // the MIPS ABI.
96 __ mov(T9, S5); 93 __ mov(T9, S5);
97 __ jalr(T9); 94 __ jalr(T9);
98 95
99 ASSERT(retval_offset == 3 * kWordSize); 96 ASSERT(retval_offset == 3 * kWordSize);
100 // Retval is next to 1st argument. 97 // Retval is next to 1st argument.
101 __ delay_slot()->addiu(A3, A2, Immediate(kWordSize)); 98 __ delay_slot()->addiu(A3, A2, Immediate(kWordSize));
102 __ Comment("CallToRuntimeStub return"); 99 __ Comment("CallToRuntimeStub return");
103 100
104 // Mark that the isolate is executing Dart code. 101 // Mark that the thread is executing Dart code.
105 __ LoadImmediate(A2, VMTag::kDartTagId); 102 __ LoadImmediate(A2, VMTag::kDartTagId);
106 __ sw(A2, Address(S2, Isolate::vm_tag_offset())); 103 __ sw(A2, Assembler::VMTagAddress());
107 104
108 // Reset exit frame information in Isolate structure. 105 // Reset exit frame information in Isolate structure.
109 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset())); 106 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset()));
110 107
111 __ LeaveStubFrameAndReturn(); 108 __ LeaveStubFrameAndReturn();
112 } 109 }
113 110
114 111
115 // Print the stop message. 112 // Print the stop message.
116 DEFINE_LEAF_RUNTIME_ENTRY(void, PrintStopMessage, 1, const char* message) { 113 DEFINE_LEAF_RUNTIME_ENTRY(void, PrintStopMessage, 1, const char* message) {
(...skipping 23 matching lines...) Expand all
140 void StubCode::GenerateCallNativeCFunctionStub(Assembler* assembler) { 137 void StubCode::GenerateCallNativeCFunctionStub(Assembler* assembler) {
141 const intptr_t thread_offset = NativeArguments::thread_offset(); 138 const intptr_t thread_offset = NativeArguments::thread_offset();
142 const intptr_t argc_tag_offset = NativeArguments::argc_tag_offset(); 139 const intptr_t argc_tag_offset = NativeArguments::argc_tag_offset();
143 const intptr_t argv_offset = NativeArguments::argv_offset(); 140 const intptr_t argv_offset = NativeArguments::argv_offset();
144 const intptr_t retval_offset = NativeArguments::retval_offset(); 141 const intptr_t retval_offset = NativeArguments::retval_offset();
145 142
146 __ SetPrologueOffset(); 143 __ SetPrologueOffset();
147 __ Comment("CallNativeCFunctionStub"); 144 __ Comment("CallNativeCFunctionStub");
148 __ EnterStubFrame(); 145 __ EnterStubFrame();
149 146
150 COMPILE_ASSERT((kAbiPreservedCpuRegs & (1 << S2)) != 0);
151 __ LoadIsolate(S2);
152
153 // Save exit frame information to enable stack walking as we are about 147 // Save exit frame information to enable stack walking as we are about
154 // to transition to native code. 148 // to transition to native code.
155 __ sw(FP, Address(THR, Thread::top_exit_frame_info_offset())); 149 __ sw(FP, Address(THR, Thread::top_exit_frame_info_offset()));
156 150
157 #if defined(DEBUG) 151 #if defined(DEBUG)
158 { Label ok; 152 { Label ok;
159 // Check that we are always entering from Dart code. 153 // Check that we are always entering from Dart code.
160 __ lw(T0, Address(S2, Isolate::vm_tag_offset())); 154 __ lw(T0, Assembler::VMTagAddress());
161 __ BranchEqual(T0, Immediate(VMTag::kDartTagId), &ok); 155 __ BranchEqual(T0, Immediate(VMTag::kDartTagId), &ok);
162 __ Stop("Not coming from Dart code."); 156 __ Stop("Not coming from Dart code.");
163 __ Bind(&ok); 157 __ Bind(&ok);
164 } 158 }
165 #endif 159 #endif
166 160
167 // Mark that the isolate is executing Native code. 161 // Mark that the thread is executing native code.
168 __ sw(T5, Address(S2, Isolate::vm_tag_offset())); 162 __ sw(T5, Assembler::VMTagAddress());
169 163
170 // Initialize NativeArguments structure and call native function. 164 // Initialize NativeArguments structure and call native function.
171 // Registers A0, A1, A2, and A3 are used. 165 // Registers A0, A1, A2, and A3 are used.
172 166
173 ASSERT(thread_offset == 0 * kWordSize); 167 ASSERT(thread_offset == 0 * kWordSize);
174 // Set thread in NativeArgs. 168 // Set thread in NativeArgs.
175 __ mov(A0, THR); 169 __ mov(A0, THR);
176 170
177 // There are no native calls to closures, so we do not need to set the tag 171 // There are no native calls to closures, so we do not need to set the tag
178 // bits kClosureFunctionBit and kInstanceFunctionBit in argc_tag_. 172 // bits kClosureFunctionBit and kInstanceFunctionBit in argc_tag_.
(...skipping 19 matching lines...) Expand all
198 192
199 193
200 __ mov(A1, T5); // Pass the function entrypoint. 194 __ mov(A1, T5); // Pass the function entrypoint.
201 __ ReserveAlignedFrameSpace(2 * kWordSize); // Just passing A0, A1. 195 __ ReserveAlignedFrameSpace(2 * kWordSize); // Just passing A0, A1.
202 196
203 // Call native wrapper function or redirection via simulator. 197 // Call native wrapper function or redirection via simulator.
204 __ lw(T9, Address(THR, Thread::native_call_wrapper_entry_point_offset())); 198 __ lw(T9, Address(THR, Thread::native_call_wrapper_entry_point_offset()));
205 __ jalr(T9); 199 __ jalr(T9);
206 __ Comment("CallNativeCFunctionStub return"); 200 __ Comment("CallNativeCFunctionStub return");
207 201
208 // Mark that the isolate is executing Dart code. 202 // Mark that the thread is executing Dart code.
209 __ LoadImmediate(A2, VMTag::kDartTagId); 203 __ LoadImmediate(A2, VMTag::kDartTagId);
210 __ sw(A2, Address(S2, Isolate::vm_tag_offset())); 204 __ sw(A2, Assembler::VMTagAddress());
211 205
212 // Reset exit frame information in Isolate structure. 206 // Reset exit frame information in Isolate structure.
213 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset())); 207 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset()));
214 208
215 __ LeaveStubFrameAndReturn(); 209 __ LeaveStubFrameAndReturn();
216 } 210 }
217 211
218 212
219 // Input parameters: 213 // Input parameters:
220 // RA : return address. 214 // RA : return address.
221 // SP : address of return value. 215 // SP : address of return value.
222 // T5 : address of the native function to call. 216 // T5 : address of the native function to call.
223 // A2 : address of first argument in argument array. 217 // A2 : address of first argument in argument array.
224 // A1 : argc_tag including number of arguments and function kind. 218 // A1 : argc_tag including number of arguments and function kind.
225 void StubCode::GenerateCallBootstrapCFunctionStub(Assembler* assembler) { 219 void StubCode::GenerateCallBootstrapCFunctionStub(Assembler* assembler) {
226 const intptr_t thread_offset = NativeArguments::thread_offset(); 220 const intptr_t thread_offset = NativeArguments::thread_offset();
227 const intptr_t argc_tag_offset = NativeArguments::argc_tag_offset(); 221 const intptr_t argc_tag_offset = NativeArguments::argc_tag_offset();
228 const intptr_t argv_offset = NativeArguments::argv_offset(); 222 const intptr_t argv_offset = NativeArguments::argv_offset();
229 const intptr_t retval_offset = NativeArguments::retval_offset(); 223 const intptr_t retval_offset = NativeArguments::retval_offset();
230 224
231 __ SetPrologueOffset(); 225 __ SetPrologueOffset();
232 __ Comment("CallNativeCFunctionStub"); 226 __ Comment("CallNativeCFunctionStub");
233 __ EnterStubFrame(); 227 __ EnterStubFrame();
234 228
235 COMPILE_ASSERT((kAbiPreservedCpuRegs & (1 << S2)) != 0);
236 __ LoadIsolate(S2);
237
238 // Save exit frame information to enable stack walking as we are about 229 // Save exit frame information to enable stack walking as we are about
239 // to transition to native code. 230 // to transition to native code.
240 __ sw(FP, Address(THR, Thread::top_exit_frame_info_offset())); 231 __ sw(FP, Address(THR, Thread::top_exit_frame_info_offset()));
241 232
242 #if defined(DEBUG) 233 #if defined(DEBUG)
243 { Label ok; 234 { Label ok;
244 // Check that we are always entering from Dart code. 235 // Check that we are always entering from Dart code.
245 __ lw(T0, Address(S2, Isolate::vm_tag_offset())); 236 __ lw(T0, Assembler::VMTagAddress());
246 __ BranchEqual(T0, Immediate(VMTag::kDartTagId), &ok); 237 __ BranchEqual(T0, Immediate(VMTag::kDartTagId), &ok);
247 __ Stop("Not coming from Dart code."); 238 __ Stop("Not coming from Dart code.");
248 __ Bind(&ok); 239 __ Bind(&ok);
249 } 240 }
250 #endif 241 #endif
251 242
252 // Mark that the isolate is executing Native code. 243 // Mark that the thread is executing native code.
253 __ sw(T5, Address(S2, Isolate::vm_tag_offset())); 244 __ sw(T5, Assembler::VMTagAddress());
254 245
255 // Initialize NativeArguments structure and call native function. 246 // Initialize NativeArguments structure and call native function.
256 // Registers A0, A1, A2, and A3 are used. 247 // Registers A0, A1, A2, and A3 are used.
257 248
258 ASSERT(thread_offset == 0 * kWordSize); 249 ASSERT(thread_offset == 0 * kWordSize);
259 // Set thread in NativeArgs. 250 // Set thread in NativeArgs.
260 __ mov(A0, THR); 251 __ mov(A0, THR);
261 252
262 // There are no native calls to closures, so we do not need to set the tag 253 // There are no native calls to closures, so we do not need to set the tag
263 // bits kClosureFunctionBit and kInstanceFunctionBit in argc_tag_. 254 // bits kClosureFunctionBit and kInstanceFunctionBit in argc_tag_.
(...skipping 20 matching lines...) Expand all
284 __ ReserveAlignedFrameSpace(kWordSize); // Just passing A0. 275 __ ReserveAlignedFrameSpace(kWordSize); // Just passing A0.
285 276
286 // Call native function or redirection via simulator. 277 // Call native function or redirection via simulator.
287 278
288 // We defensively always jalr through T9 because it is sometimes required by 279 // We defensively always jalr through T9 because it is sometimes required by
289 // the MIPS ABI. 280 // the MIPS ABI.
290 __ mov(T9, T5); 281 __ mov(T9, T5);
291 __ jalr(T9); 282 __ jalr(T9);
292 __ Comment("CallNativeCFunctionStub return"); 283 __ Comment("CallNativeCFunctionStub return");
293 284
294 // Mark that the isolate is executing Dart code. 285 // Mark that the thread is executing Dart code.
295 __ LoadImmediate(A2, VMTag::kDartTagId); 286 __ LoadImmediate(A2, VMTag::kDartTagId);
296 __ sw(A2, Address(S2, Isolate::vm_tag_offset())); 287 __ sw(A2, Assembler::VMTagAddress());
297 288
298 // Reset exit frame information in Isolate structure. 289 // Reset exit frame information in Isolate structure.
299 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset())); 290 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset()));
300 291
301 __ LeaveStubFrameAndReturn(); 292 __ LeaveStubFrameAndReturn();
302 } 293 }
303 294
304 295
305 // Input parameters: 296 // Input parameters:
306 // S4: arguments descriptor array. 297 // S4: arguments descriptor array.
(...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 } 819 }
829 820
830 // We now load the pool pointer(PP) with a GC safe value as we are about 821 // We now load the pool pointer(PP) with a GC safe value as we are about
831 // to invoke dart code. 822 // to invoke dart code.
832 __ LoadImmediate(PP, 0); 823 __ LoadImmediate(PP, 0);
833 824
834 // Set up THR, which caches the current thread in Dart code. 825 // Set up THR, which caches the current thread in Dart code.
835 if (THR != A3) { 826 if (THR != A3) {
836 __ mov(THR, A3); 827 __ mov(THR, A3);
837 } 828 }
838 __ LoadIsolate(T2);
839 829
840 // Save the current VMTag on the stack. 830 // Save the current VMTag on the stack.
841 __ lw(T1, Address(T2, Isolate::vm_tag_offset())); 831 __ lw(T1, Assembler::VMTagAddress());
842 __ sw(T1, Address(SP, 2 * kWordSize)); 832 __ sw(T1, Address(SP, 2 * kWordSize));
843 833
844 // Mark that the isolate is executing Dart code. 834 // Mark that the thread is executing Dart code.
845 __ LoadImmediate(T0, VMTag::kDartTagId); 835 __ LoadImmediate(T0, VMTag::kDartTagId);
846 __ sw(T0, Address(T2, Isolate::vm_tag_offset())); 836 __ sw(T0, Assembler::VMTagAddress());
847 837
848 // Save top resource and top exit frame info. Use T0 as a temporary register. 838 // Save top resource and top exit frame info. Use T0 as a temporary register.
849 // StackFrameIterator reads the top exit frame info saved in this frame. 839 // StackFrameIterator reads the top exit frame info saved in this frame.
850 __ lw(T0, Address(THR, Thread::top_resource_offset())); 840 __ lw(T0, Address(THR, Thread::top_resource_offset()));
851 __ sw(ZR, Address(THR, Thread::top_resource_offset())); 841 __ sw(ZR, Address(THR, Thread::top_resource_offset()));
852 __ sw(T0, Address(SP, 1 * kWordSize)); 842 __ sw(T0, Address(SP, 1 * kWordSize));
853 __ lw(T0, Address(THR, Thread::top_exit_frame_info_offset())); 843 __ lw(T0, Address(THR, Thread::top_exit_frame_info_offset()));
854 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset())); 844 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset()));
855 // kExitLinkSlotFromEntryFp must be kept in sync with the code below. 845 // kExitLinkSlotFromEntryFp must be kept in sync with the code below.
856 ASSERT(kExitLinkSlotFromEntryFp == -24); 846 ASSERT(kExitLinkSlotFromEntryFp == -24);
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
889 // We are calling into Dart code, here, so there is no need to call through 879 // We are calling into Dart code, here, so there is no need to call through
890 // T9 to match the ABI. 880 // T9 to match the ABI.
891 __ lw(CODE_REG, Address(A0, VMHandles::kOffsetOfRawPtrInHandle)); 881 __ lw(CODE_REG, Address(A0, VMHandles::kOffsetOfRawPtrInHandle));
892 __ lw(A0, FieldAddress(CODE_REG, Code::entry_point_offset())); 882 __ lw(A0, FieldAddress(CODE_REG, Code::entry_point_offset()));
893 __ jalr(A0); // S4 is the arguments descriptor array. 883 __ jalr(A0); // S4 is the arguments descriptor array.
894 __ Comment("InvokeDartCodeStub return"); 884 __ Comment("InvokeDartCodeStub return");
895 885
896 // Get rid of arguments pushed on the stack. 886 // Get rid of arguments pushed on the stack.
897 __ AddImmediate(SP, FP, kExitLinkSlotFromEntryFp * kWordSize); 887 __ AddImmediate(SP, FP, kExitLinkSlotFromEntryFp * kWordSize);
898 888
899 __ LoadIsolate(S2);
900 889
901 // Restore the current VMTag from the stack. 890 // Restore the current VMTag from the stack.
902 __ lw(T1, Address(SP, 2 * kWordSize)); 891 __ lw(T1, Address(SP, 2 * kWordSize));
903 __ sw(T1, Address(S2, Isolate::vm_tag_offset())); 892 __ sw(T1, Assembler::VMTagAddress());
904 893
905 // Restore the saved top resource and top exit frame info back into the 894 // Restore the saved top resource and top exit frame info back into the
906 // Isolate structure. Uses T0 as a temporary register for this. 895 // Isolate structure. Uses T0 as a temporary register for this.
907 __ lw(T0, Address(SP, 1 * kWordSize)); 896 __ lw(T0, Address(SP, 1 * kWordSize));
908 __ sw(T0, Address(THR, Thread::top_resource_offset())); 897 __ sw(T0, Address(THR, Thread::top_resource_offset()));
909 __ lw(T0, Address(SP, 0 * kWordSize)); 898 __ lw(T0, Address(SP, 0 * kWordSize));
910 __ sw(T0, Address(THR, Thread::top_exit_frame_info_offset())); 899 __ sw(T0, Address(THR, Thread::top_exit_frame_info_offset()));
911 900
912 // Restore C++ ABI callee-saved registers. 901 // Restore C++ ABI callee-saved registers.
913 for (int i = S0; i <= S7; i++) { 902 for (int i = S0; i <= S7; i++) {
(...skipping 1127 matching lines...) Expand 10 before | Expand all | Expand 10 after
2041 // Does not return. 2030 // Does not return.
2042 void StubCode::GenerateJumpToExceptionHandlerStub(Assembler* assembler) { 2031 void StubCode::GenerateJumpToExceptionHandlerStub(Assembler* assembler) {
2043 ASSERT(kExceptionObjectReg == V0); 2032 ASSERT(kExceptionObjectReg == V0);
2044 ASSERT(kStackTraceObjectReg == V1); 2033 ASSERT(kStackTraceObjectReg == V1);
2045 __ mov(V0, A3); // Exception object. 2034 __ mov(V0, A3); // Exception object.
2046 // MIPS ABI reserves stack space for all arguments. The StackTrace object is 2035 // MIPS ABI reserves stack space for all arguments. The StackTrace object is
2047 // the last of five arguments, so it is first pushed on the stack. 2036 // the last of five arguments, so it is first pushed on the stack.
2048 __ lw(V1, Address(SP, 4 * kWordSize)); // StackTrace object. 2037 __ lw(V1, Address(SP, 4 * kWordSize)); // StackTrace object.
2049 __ mov(FP, A2); // Frame_pointer. 2038 __ mov(FP, A2); // Frame_pointer.
2050 __ lw(THR, Address(SP, 5 * kWordSize)); // Thread. 2039 __ lw(THR, Address(SP, 5 * kWordSize)); // Thread.
2051 __ LoadIsolate(A3);
2052 // Set tag. 2040 // Set tag.
2053 __ LoadImmediate(A2, VMTag::kDartTagId); 2041 __ LoadImmediate(A2, VMTag::kDartTagId);
2054 __ sw(A2, Address(A3, Isolate::vm_tag_offset())); 2042 __ sw(A2, Assembler::VMTagAddress());
2055 // Clear top exit frame. 2043 // Clear top exit frame.
2056 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset())); 2044 __ sw(ZR, Address(THR, Thread::top_exit_frame_info_offset()));
2057 2045
2058 __ jr(A0); // Jump to the exception handler code. 2046 __ jr(A0); // Jump to the exception handler code.
2059 __ delay_slot()->mov(SP, A1); // Stack pointer. 2047 __ delay_slot()->mov(SP, A1); // Stack pointer.
2060 } 2048 }
2061 2049
2062 2050
2063 // Calls to the runtime to optimize the given function. 2051 // Calls to the runtime to optimize the given function.
2064 // T0: function to be reoptimized. 2052 // T0: function to be reoptimized.
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
2271 // Result: 2259 // Result:
2272 // T1: entry point. 2260 // T1: entry point.
2273 void StubCode::GenerateMegamorphicLookupStub(Assembler* assembler) { 2261 void StubCode::GenerateMegamorphicLookupStub(Assembler* assembler) {
2274 EmitMegamorphicLookup(assembler, T0, T1, T1); 2262 EmitMegamorphicLookup(assembler, T0, T1, T1);
2275 __ Ret(); 2263 __ Ret();
2276 } 2264 }
2277 2265
2278 } // namespace dart 2266 } // namespace dart
2279 2267
2280 #endif // defined TARGET_ARCH_MIPS 2268 #endif // defined TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « runtime/vm/stub_code_ia32.cc ('k') | runtime/vm/stub_code_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698