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_ARM. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM. |
6 #if defined(TARGET_ARCH_ARM) | 6 #if defined(TARGET_ARCH_ARM) |
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 1540 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1551 __ LoadClassIdMayBeSmi(R1, R0); | 1551 __ LoadClassIdMayBeSmi(R1, R0); |
1552 __ CompareImmediate(R1, kClosureCid); | 1552 __ CompareImmediate(R1, kClosureCid); |
1553 __ b(&fall_through, EQ); // Instance is a closure. | 1553 __ b(&fall_through, EQ); // Instance is a closure. |
1554 __ LoadClassById(R2, R1); | 1554 __ LoadClassById(R2, R1); |
1555 // R2: class of instance (R0). | 1555 // R2: class of instance (R0). |
1556 | 1556 |
1557 __ ldrh(R3, FieldAddress(R2, Class::num_type_arguments_offset())); | 1557 __ ldrh(R3, FieldAddress(R2, Class::num_type_arguments_offset())); |
1558 __ CompareImmediate(R3, 0); | 1558 __ CompareImmediate(R3, 0); |
1559 __ b(&fall_through, NE); | 1559 __ b(&fall_through, NE); |
1560 | 1560 |
1561 __ ldr(R0, FieldAddress(R2, Class::canonical_types_offset())); | 1561 __ ldr(R0, FieldAddress(R2, Class::canonical_type_offset())); |
1562 __ CompareObject(R0, Object::null_object()); | 1562 __ CompareObject(R0, Object::null_object()); |
1563 __ b(&fall_through, EQ); | 1563 __ b(&fall_through, EQ); |
1564 __ Ret(); | 1564 __ Ret(); |
1565 | 1565 |
1566 __ Bind(&fall_through); | 1566 __ Bind(&fall_through); |
1567 } | 1567 } |
1568 | 1568 |
1569 | 1569 |
1570 void Intrinsifier::String_getHashCode(Assembler* assembler) { | 1570 void Intrinsifier::String_getHashCode(Assembler* assembler) { |
1571 __ ldr(R0, Address(SP, 0 * kWordSize)); | 1571 __ ldr(R0, Address(SP, 0 * kWordSize)); |
(...skipping 552 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2124 __ Ret(); | 2124 __ Ret(); |
2125 // Enabled. | 2125 // Enabled. |
2126 __ Bind(&true_label); | 2126 __ Bind(&true_label); |
2127 __ LoadObject(R0, Bool::True()); | 2127 __ LoadObject(R0, Bool::True()); |
2128 __ Ret(); | 2128 __ Ret(); |
2129 } | 2129 } |
2130 | 2130 |
2131 } // namespace dart | 2131 } // namespace dart |
2132 | 2132 |
2133 #endif // defined TARGET_ARCH_ARM | 2133 #endif // defined TARGET_ARCH_ARM |
OLD | NEW |