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" // Needed here to get TARGET_ARCH_MIPS. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_MIPS. |
6 #if defined(TARGET_ARCH_MIPS) | 6 #if defined(TARGET_ARCH_MIPS) |
7 | 7 |
8 #include "vm/intrinsifier.h" | 8 #include "vm/intrinsifier.h" |
9 | 9 |
10 #include "vm/assembler.h" | 10 #include "vm/assembler.h" |
(...skipping 2118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2129 __ lw(T1, Address(SP, kRegExpParamOffset)); | 2129 __ lw(T1, Address(SP, kRegExpParamOffset)); |
2130 __ lw(T3, Address(SP, kStringParamOffset)); | 2130 __ lw(T3, Address(SP, kStringParamOffset)); |
2131 __ LoadClassId(T2, T3); | 2131 __ LoadClassId(T2, T3); |
2132 __ AddImmediate(T2, -kOneByteStringCid); | 2132 __ AddImmediate(T2, -kOneByteStringCid); |
2133 __ sll(T2, T2, kWordSizeLog2); | 2133 __ sll(T2, T2, kWordSizeLog2); |
2134 __ addu(T2, T2, T1); | 2134 __ addu(T2, T2, T1); |
2135 __ lw(T0, FieldAddress(T2, JSRegExp::function_offset(kOneByteStringCid))); | 2135 __ lw(T0, FieldAddress(T2, JSRegExp::function_offset(kOneByteStringCid))); |
2136 | 2136 |
2137 // Registers are now set up for the lazy compile stub. It expects the function | 2137 // Registers are now set up for the lazy compile stub. It expects the function |
2138 // in T0, the argument descriptor in S4, and IC-Data in S5. | 2138 // in T0, the argument descriptor in S4, and IC-Data in S5. |
2139 static const intptr_t arg_count = RegExpMacroAssembler::kParamCount; | |
2140 __ LoadObject(S4, Array::Handle(ArgumentsDescriptor::New(arg_count))); | |
2141 __ mov(S5, ZR); | 2139 __ mov(S5, ZR); |
2142 | 2140 |
2143 // Tail-call the function. | 2141 // Tail-call the function. |
2144 __ lw(T3, FieldAddress(T0, Function::entry_point_offset())); | 2142 __ lw(T3, FieldAddress(T0, Function::entry_point_offset())); |
2145 __ jr(T3); | 2143 __ jr(T3); |
2146 } | 2144 } |
2147 | 2145 |
2148 | 2146 |
2149 // On stack: user tag (+0). | 2147 // On stack: user tag (+0). |
2150 void Intrinsifier::UserTag_makeCurrent(Assembler* assembler) { | 2148 void Intrinsifier::UserTag_makeCurrent(Assembler* assembler) { |
(...skipping 23 matching lines...) Expand all Loading... |
2174 | 2172 |
2175 void Intrinsifier::Profiler_getCurrentTag(Assembler* assembler) { | 2173 void Intrinsifier::Profiler_getCurrentTag(Assembler* assembler) { |
2176 __ LoadIsolate(V0); | 2174 __ LoadIsolate(V0); |
2177 __ Ret(); | 2175 __ Ret(); |
2178 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); | 2176 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); |
2179 } | 2177 } |
2180 | 2178 |
2181 } // namespace dart | 2179 } // namespace dart |
2182 | 2180 |
2183 #endif // defined TARGET_ARCH_MIPS | 2181 #endif // defined TARGET_ARCH_MIPS |
OLD | NEW |