| 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 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 231 case 4: return 2; | 231 case 4: return 2; |
| 232 case 8: return 3; | 232 case 8: return 3; |
| 233 case 16: return 4; | 233 case 16: return 4; |
| 234 } | 234 } |
| 235 UNREACHABLE(); | 235 UNREACHABLE(); |
| 236 return -1; | 236 return -1; |
| 237 } | 237 } |
| 238 | 238 |
| 239 | 239 |
| 240 #define TYPED_DATA_ALLOCATOR(clazz) \ | 240 #define TYPED_DATA_ALLOCATOR(clazz) \ |
| 241 void Intrinsifier::TypedData_##clazz##_new(Assembler* assembler) { \ | |
| 242 intptr_t size = TypedData::ElementSizeInBytes(kTypedData##clazz##Cid); \ | |
| 243 intptr_t max_len = TypedData::MaxElements(kTypedData##clazz##Cid); \ | |
| 244 int shift = GetScaleFactor(size); \ | |
| 245 TYPED_ARRAY_ALLOCATION(TypedData, kTypedData##clazz##Cid, max_len, shift); \ | |
| 246 } \ | |
| 247 void Intrinsifier::TypedData_##clazz##_factory(Assembler* assembler) { \ | 241 void Intrinsifier::TypedData_##clazz##_factory(Assembler* assembler) { \ |
| 248 intptr_t size = TypedData::ElementSizeInBytes(kTypedData##clazz##Cid); \ | 242 intptr_t size = TypedData::ElementSizeInBytes(kTypedData##clazz##Cid); \ |
| 249 intptr_t max_len = TypedData::MaxElements(kTypedData##clazz##Cid); \ | 243 intptr_t max_len = TypedData::MaxElements(kTypedData##clazz##Cid); \ |
| 250 int shift = GetScaleFactor(size); \ | 244 int shift = GetScaleFactor(size); \ |
| 251 TYPED_ARRAY_ALLOCATION(TypedData, kTypedData##clazz##Cid, max_len, shift); \ | 245 TYPED_ARRAY_ALLOCATION(TypedData, kTypedData##clazz##Cid, max_len, shift); \ |
| 252 } | 246 } |
| 253 CLASS_LIST_TYPED_DATA(TYPED_DATA_ALLOCATOR) | 247 CLASS_LIST_TYPED_DATA(TYPED_DATA_ALLOCATOR) |
| 254 #undef TYPED_DATA_ALLOCATOR | 248 #undef TYPED_DATA_ALLOCATOR |
| 255 | 249 |
| 256 | 250 |
| (...skipping 1971 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2228 | 2222 |
| 2229 void Intrinsifier::Profiler_getCurrentTag(Assembler* assembler) { | 2223 void Intrinsifier::Profiler_getCurrentTag(Assembler* assembler) { |
| 2230 __ LoadIsolate(V0); | 2224 __ LoadIsolate(V0); |
| 2231 __ Ret(); | 2225 __ Ret(); |
| 2232 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); | 2226 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); |
| 2233 } | 2227 } |
| 2234 | 2228 |
| 2235 } // namespace dart | 2229 } // namespace dart |
| 2236 | 2230 |
| 2237 #endif // defined TARGET_ARCH_MIPS | 2231 #endif // defined TARGET_ARCH_MIPS |
| OLD | NEW |