OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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/crankshaft/arm64/lithium-codegen-arm64.h" | 5 #include "src/crankshaft/arm64/lithium-codegen-arm64.h" |
6 | 6 |
7 #include "src/arm64/frames-arm64.h" | 7 #include "src/arm64/frames-arm64.h" |
8 #include "src/base/bits.h" | 8 #include "src/base/bits.h" |
9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 2815 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2826 // Deoptimize if the object needs to be access checked. | 2826 // Deoptimize if the object needs to be access checked. |
2827 __ Ldrb(object_instance_type, | 2827 __ Ldrb(object_instance_type, |
2828 FieldMemOperand(object_map, Map::kBitFieldOffset)); | 2828 FieldMemOperand(object_map, Map::kBitFieldOffset)); |
2829 __ Tst(object_instance_type, Operand(1 << Map::kIsAccessCheckNeeded)); | 2829 __ Tst(object_instance_type, Operand(1 << Map::kIsAccessCheckNeeded)); |
2830 DeoptimizeIf(ne, instr, Deoptimizer::kAccessCheck); | 2830 DeoptimizeIf(ne, instr, Deoptimizer::kAccessCheck); |
2831 // Deoptimize for proxies. | 2831 // Deoptimize for proxies. |
2832 __ CompareInstanceType(object_map, object_instance_type, JS_PROXY_TYPE); | 2832 __ CompareInstanceType(object_map, object_instance_type, JS_PROXY_TYPE); |
2833 DeoptimizeIf(eq, instr, Deoptimizer::kProxy); | 2833 DeoptimizeIf(eq, instr, Deoptimizer::kProxy); |
2834 | 2834 |
2835 __ Ldr(object_prototype, FieldMemOperand(object_map, Map::kPrototypeOffset)); | 2835 __ Ldr(object_prototype, FieldMemOperand(object_map, Map::kPrototypeOffset)); |
| 2836 __ CompareRoot(object_prototype, Heap::kNullValueRootIndex); |
| 2837 __ B(eq, instr->FalseLabel(chunk_)); |
2836 __ Cmp(object_prototype, prototype); | 2838 __ Cmp(object_prototype, prototype); |
2837 __ B(eq, instr->TrueLabel(chunk_)); | 2839 __ B(eq, instr->TrueLabel(chunk_)); |
2838 __ CompareRoot(object_prototype, Heap::kNullValueRootIndex); | |
2839 __ B(eq, instr->FalseLabel(chunk_)); | |
2840 __ Ldr(object_map, FieldMemOperand(object_prototype, HeapObject::kMapOffset)); | 2840 __ Ldr(object_map, FieldMemOperand(object_prototype, HeapObject::kMapOffset)); |
2841 __ B(&loop); | 2841 __ B(&loop); |
2842 } | 2842 } |
2843 | 2843 |
2844 | 2844 |
2845 void LCodeGen::DoInstructionGap(LInstructionGap* instr) { | 2845 void LCodeGen::DoInstructionGap(LInstructionGap* instr) { |
2846 DoGap(instr); | 2846 DoGap(instr); |
2847 } | 2847 } |
2848 | 2848 |
2849 | 2849 |
(...skipping 2901 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5751 // Index is equal to negated out of object property index plus 1. | 5751 // Index is equal to negated out of object property index plus 1. |
5752 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2)); | 5752 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2)); |
5753 __ Ldr(result, FieldMemOperand(result, | 5753 __ Ldr(result, FieldMemOperand(result, |
5754 FixedArray::kHeaderSize - kPointerSize)); | 5754 FixedArray::kHeaderSize - kPointerSize)); |
5755 __ Bind(deferred->exit()); | 5755 __ Bind(deferred->exit()); |
5756 __ Bind(&done); | 5756 __ Bind(&done); |
5757 } | 5757 } |
5758 | 5758 |
5759 } // namespace internal | 5759 } // namespace internal |
5760 } // namespace v8 | 5760 } // namespace v8 |
OLD | NEW |