| 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 #if V8_TARGET_ARCH_ARM64 | 5 #if V8_TARGET_ARCH_ARM64 |
| 6 | 6 |
| 7 #include "src/arm64/frames-arm64.h" | 7 #include "src/arm64/frames-arm64.h" |
| 8 #include "src/codegen.h" | 8 #include "src/codegen.h" |
| 9 #include "src/debug/debug.h" | 9 #include "src/debug/debug.h" |
| 10 #include "src/deoptimizer.h" | 10 #include "src/deoptimizer.h" |
| (...skipping 2851 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2862 ContextMemOperand( | 2862 ContextMemOperand( |
| 2863 scratch2, Context::INITIAL_ARRAY_ITERATOR_PROTOTYPE_MAP_INDEX)); | 2863 scratch2, Context::INITIAL_ARRAY_ITERATOR_PROTOTYPE_MAP_INDEX)); |
| 2864 __ Cmp(scratch, scratch2); | 2864 __ Cmp(scratch, scratch2); |
| 2865 __ B(ne, &runtime_call); | 2865 __ B(ne, &runtime_call); |
| 2866 | 2866 |
| 2867 // For FastPacked kinds, iteration will have the same effect as simply | 2867 // For FastPacked kinds, iteration will have the same effect as simply |
| 2868 // accessing each property in order. | 2868 // accessing each property in order. |
| 2869 Label no_protector_check; | 2869 Label no_protector_check; |
| 2870 __ Ldr(scratch, FieldMemOperand(spread_map, Map::kBitField2Offset)); | 2870 __ Ldr(scratch, FieldMemOperand(spread_map, Map::kBitField2Offset)); |
| 2871 __ DecodeField<Map::ElementsKindBits>(scratch); | 2871 __ DecodeField<Map::ElementsKindBits>(scratch); |
| 2872 __ Cmp(scratch, LAST_FAST_ELEMENTS_KIND); | 2872 __ Cmp(scratch, FAST_HOLEY_ELEMENTS); |
| 2873 __ B(hi, &runtime_call); | 2873 __ B(hi, &runtime_call); |
| 2874 // For non-FastHoley kinds, we can skip the protector check. | 2874 // For non-FastHoley kinds, we can skip the protector check. |
| 2875 __ Cmp(scratch, FAST_SMI_ELEMENTS); | 2875 __ Cmp(scratch, FAST_SMI_ELEMENTS); |
| 2876 __ B(eq, &no_protector_check); | 2876 __ B(eq, &no_protector_check); |
| 2877 __ Cmp(scratch, FAST_ELEMENTS); | 2877 __ Cmp(scratch, FAST_ELEMENTS); |
| 2878 __ B(eq, &no_protector_check); | 2878 __ B(eq, &no_protector_check); |
| 2879 __ Cmp(scratch, FAST_DOUBLE_ELEMENTS); | |
| 2880 __ B(eq, &no_protector_check); | |
| 2881 // Check the ArrayProtector cell. | 2879 // Check the ArrayProtector cell. |
| 2882 __ LoadRoot(scratch, Heap::kArrayProtectorRootIndex); | 2880 __ LoadRoot(scratch, Heap::kArrayProtectorRootIndex); |
| 2883 __ Ldr(scratch, FieldMemOperand(scratch, PropertyCell::kValueOffset)); | 2881 __ Ldr(scratch, FieldMemOperand(scratch, PropertyCell::kValueOffset)); |
| 2884 __ Cmp(scratch, Smi::FromInt(Isolate::kProtectorValid)); | 2882 __ Cmp(scratch, Smi::FromInt(Isolate::kProtectorValid)); |
| 2885 __ B(ne, &runtime_call); | 2883 __ B(ne, &runtime_call); |
| 2886 | 2884 |
| 2887 __ Bind(&no_protector_check); | 2885 __ Bind(&no_protector_check); |
| 2888 // Load the FixedArray backing store. | 2886 // Load the FixedArray backing store. |
| 2889 __ Ldr(spread, FieldMemOperand(spread, JSArray::kElementsOffset)); | 2887 __ Ldr(spread, FieldMemOperand(spread, JSArray::kElementsOffset)); |
| 2890 __ B(&push_args); | 2888 __ B(&push_args); |
| (...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3133 __ Unreachable(); | 3131 __ Unreachable(); |
| 3134 } | 3132 } |
| 3135 } | 3133 } |
| 3136 | 3134 |
| 3137 #undef __ | 3135 #undef __ |
| 3138 | 3136 |
| 3139 } // namespace internal | 3137 } // namespace internal |
| 3140 } // namespace v8 | 3138 } // namespace v8 |
| 3141 | 3139 |
| 3142 #endif // V8_TARGET_ARCH_ARM | 3140 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |