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 1341 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1352 __ LoadObject(V0, Bool::False()); | 1352 __ LoadObject(V0, Bool::False()); |
1353 __ Ret(); | 1353 __ Ret(); |
1354 __ Bind(&is_true); | 1354 __ Bind(&is_true); |
1355 __ LoadObject(V0, Bool::True()); | 1355 __ LoadObject(V0, Bool::True()); |
1356 __ Ret(); | 1356 __ Ret(); |
1357 | 1357 |
1358 | 1358 |
1359 __ Bind(&is_smi); | 1359 __ Bind(&is_smi); |
1360 __ SmiUntag(T0); | 1360 __ SmiUntag(T0); |
1361 __ mtc1(T0, STMP1); | 1361 __ mtc1(T0, STMP1); |
1362 __ cvtdw(D1, STMP1); | |
1363 __ b(&double_op); | 1362 __ b(&double_op); |
| 1363 __ delay_slot()->cvtdw(D1, STMP1); |
| 1364 |
1364 | 1365 |
1365 __ Bind(&fall_through); | 1366 __ Bind(&fall_through); |
1366 } | 1367 } |
1367 | 1368 |
1368 | 1369 |
1369 void Intrinsifier::Double_greaterThan(Assembler* assembler) { | 1370 void Intrinsifier::Double_greaterThan(Assembler* assembler) { |
1370 CompareDoubles(assembler, GT); | 1371 CompareDoubles(assembler, GT); |
1371 } | 1372 } |
1372 | 1373 |
1373 | 1374 |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1415 Isolate::Current()->object_store()->double_class()); | 1416 Isolate::Current()->object_store()->double_class()); |
1416 __ TryAllocate(double_class, &fall_through, V0, T1); // Result register. | 1417 __ TryAllocate(double_class, &fall_through, V0, T1); // Result register. |
1417 __ swc1(F0, FieldAddress(V0, Double::value_offset())); | 1418 __ swc1(F0, FieldAddress(V0, Double::value_offset())); |
1418 __ Ret(); | 1419 __ Ret(); |
1419 __ delay_slot()->swc1(F1, | 1420 __ delay_slot()->swc1(F1, |
1420 FieldAddress(V0, Double::value_offset() + kWordSize)); | 1421 FieldAddress(V0, Double::value_offset() + kWordSize)); |
1421 | 1422 |
1422 __ Bind(&is_smi); | 1423 __ Bind(&is_smi); |
1423 __ SmiUntag(T0); | 1424 __ SmiUntag(T0); |
1424 __ mtc1(T0, STMP1); | 1425 __ mtc1(T0, STMP1); |
1425 __ cvtdw(D1, STMP1); | |
1426 __ b(&double_op); | 1426 __ b(&double_op); |
| 1427 __ delay_slot()->cvtdw(D1, STMP1); |
1427 | 1428 |
1428 __ Bind(&fall_through); | 1429 __ Bind(&fall_through); |
1429 } | 1430 } |
1430 | 1431 |
1431 | 1432 |
1432 void Intrinsifier::Double_add(Assembler* assembler) { | 1433 void Intrinsifier::Double_add(Assembler* assembler) { |
1433 DoubleArithmeticOperations(assembler, Token::kADD); | 1434 DoubleArithmeticOperations(assembler, Token::kADD); |
1434 } | 1435 } |
1435 | 1436 |
1436 | 1437 |
(...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2242 | 2243 |
2243 void Intrinsifier::Profiler_getCurrentTag(Assembler* assembler) { | 2244 void Intrinsifier::Profiler_getCurrentTag(Assembler* assembler) { |
2244 __ LoadIsolate(V0); | 2245 __ LoadIsolate(V0); |
2245 __ Ret(); | 2246 __ Ret(); |
2246 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); | 2247 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); |
2247 } | 2248 } |
2248 | 2249 |
2249 } // namespace dart | 2250 } // namespace dart |
2250 | 2251 |
2251 #endif // defined TARGET_ARCH_MIPS | 2252 #endif // defined TARGET_ARCH_MIPS |
OLD | NEW |