OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_ARM | 7 #if V8_TARGET_ARCH_ARM |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 3643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3654 __ sub(r0, r0, Operand(r1)); | 3654 __ sub(r0, r0, Operand(r1)); |
3655 __ Ret(); | 3655 __ Ret(); |
3656 | 3656 |
3657 __ bind(&miss); | 3657 __ bind(&miss); |
3658 GenerateMiss(masm); | 3658 GenerateMiss(masm); |
3659 } | 3659 } |
3660 | 3660 |
3661 | 3661 |
3662 void CompareICStub::GenerateKnownObjects(MacroAssembler* masm) { | 3662 void CompareICStub::GenerateKnownObjects(MacroAssembler* masm) { |
3663 Label miss; | 3663 Label miss; |
| 3664 Handle<WeakCell> cell = Map::WeakCellForMap(known_map_); |
3664 __ and_(r2, r1, Operand(r0)); | 3665 __ and_(r2, r1, Operand(r0)); |
3665 __ JumpIfSmi(r2, &miss); | 3666 __ JumpIfSmi(r2, &miss); |
| 3667 __ GetWeakValue(r4, cell); |
3666 __ ldr(r2, FieldMemOperand(r0, HeapObject::kMapOffset)); | 3668 __ ldr(r2, FieldMemOperand(r0, HeapObject::kMapOffset)); |
3667 __ ldr(r3, FieldMemOperand(r1, HeapObject::kMapOffset)); | 3669 __ ldr(r3, FieldMemOperand(r1, HeapObject::kMapOffset)); |
3668 __ cmp(r2, Operand(known_map_)); | 3670 __ cmp(r2, r4); |
3669 __ b(ne, &miss); | 3671 __ b(ne, &miss); |
3670 __ cmp(r3, Operand(known_map_)); | 3672 __ cmp(r3, r4); |
3671 __ b(ne, &miss); | 3673 __ b(ne, &miss); |
3672 | 3674 |
3673 __ sub(r0, r0, Operand(r1)); | 3675 __ sub(r0, r0, Operand(r1)); |
3674 __ Ret(); | 3676 __ Ret(); |
3675 | 3677 |
3676 __ bind(&miss); | 3678 __ bind(&miss); |
3677 GenerateMiss(masm); | 3679 GenerateMiss(masm); |
3678 } | 3680 } |
3679 | 3681 |
3680 | 3682 |
(...skipping 1262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4943 kStackUnwindSpace, NULL, | 4945 kStackUnwindSpace, NULL, |
4944 MemOperand(fp, 6 * kPointerSize), NULL); | 4946 MemOperand(fp, 6 * kPointerSize), NULL); |
4945 } | 4947 } |
4946 | 4948 |
4947 | 4949 |
4948 #undef __ | 4950 #undef __ |
4949 | 4951 |
4950 } } // namespace v8::internal | 4952 } } // namespace v8::internal |
4951 | 4953 |
4952 #endif // V8_TARGET_ARCH_ARM | 4954 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |