Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(272)

Side by Side Diff: src/arm/code-stubs-arm.cc

Issue 2123983004: [ic] Split megamorphic stub cache in two caches (for loads and for stores). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@flags-fix
Patch Set: Rebasing Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | src/arm64/code-stubs-arm64.cc » ('j') | src/ic/x64/stub-cache-x64.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #if V8_TARGET_ARCH_ARM 5 #if V8_TARGET_ARCH_ARM
6 6
7 #include "src/code-stubs.h" 7 #include "src/code-stubs.h"
8 #include "src/api-arguments.h" 8 #include "src/api-arguments.h"
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 3507 matching lines...) Expand 10 before | Expand all | Expand 10 after
3518 // Is it a fixed array? 3518 // Is it a fixed array?
3519 __ bind(&try_array); 3519 __ bind(&try_array);
3520 __ ldr(scratch1, FieldMemOperand(feedback, HeapObject::kMapOffset)); 3520 __ ldr(scratch1, FieldMemOperand(feedback, HeapObject::kMapOffset));
3521 __ CompareRoot(scratch1, Heap::kFixedArrayMapRootIndex); 3521 __ CompareRoot(scratch1, Heap::kFixedArrayMapRootIndex);
3522 __ b(ne, &not_array); 3522 __ b(ne, &not_array);
3523 HandleArrayCases(masm, feedback, receiver_map, scratch1, r9, true, &miss); 3523 HandleArrayCases(masm, feedback, receiver_map, scratch1, r9, true, &miss);
3524 3524
3525 __ bind(&not_array); 3525 __ bind(&not_array);
3526 __ CompareRoot(feedback, Heap::kmegamorphic_symbolRootIndex); 3526 __ CompareRoot(feedback, Heap::kmegamorphic_symbolRootIndex);
3527 __ b(ne, &miss); 3527 __ b(ne, &miss);
3528 Code::Flags code_flags = 3528 masm->isolate()->load_stub_cache()->GenerateProbe(
3529 Code::RemoveHolderFromFlags(Code::ComputeHandlerFlags(Code::LOAD_IC)); 3529 masm, receiver, name, feedback, receiver_map, scratch1, r9);
3530 masm->isolate()->stub_cache()->GenerateProbe(masm, Code::LOAD_IC, code_flags,
3531 receiver, name, feedback,
3532 receiver_map, scratch1, r9);
3533 3530
3534 __ bind(&miss); 3531 __ bind(&miss);
3535 LoadIC::GenerateMiss(masm); 3532 LoadIC::GenerateMiss(masm);
3536 3533
3537 __ bind(&load_smi_map); 3534 __ bind(&load_smi_map);
3538 __ LoadRoot(receiver_map, Heap::kHeapNumberMapRootIndex); 3535 __ LoadRoot(receiver_map, Heap::kHeapNumberMapRootIndex);
3539 __ jmp(&compare_map); 3536 __ jmp(&compare_map);
3540 } 3537 }
3541 3538
3542 3539
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
3663 // We are using register r8, which is used for the embedded constant pool 3660 // We are using register r8, which is used for the embedded constant pool
3664 // when FLAG_enable_embedded_constant_pool is true. 3661 // when FLAG_enable_embedded_constant_pool is true.
3665 DCHECK(!FLAG_enable_embedded_constant_pool); 3662 DCHECK(!FLAG_enable_embedded_constant_pool);
3666 Register scratch2 = r8; 3663 Register scratch2 = r8;
3667 HandleArrayCases(masm, feedback, receiver_map, scratch1, scratch2, true, 3664 HandleArrayCases(masm, feedback, receiver_map, scratch1, scratch2, true,
3668 &miss); 3665 &miss);
3669 3666
3670 __ bind(&not_array); 3667 __ bind(&not_array);
3671 __ CompareRoot(feedback, Heap::kmegamorphic_symbolRootIndex); 3668 __ CompareRoot(feedback, Heap::kmegamorphic_symbolRootIndex);
3672 __ b(ne, &miss); 3669 __ b(ne, &miss);
3673 Code::Flags code_flags = 3670 masm->isolate()->store_stub_cache()->GenerateProbe(
3674 Code::RemoveHolderFromFlags(Code::ComputeHandlerFlags(Code::STORE_IC)); 3671 masm, receiver, key, feedback, receiver_map, scratch1, scratch2);
3675 masm->isolate()->stub_cache()->GenerateProbe(
3676 masm, Code::STORE_IC, code_flags, receiver, key, feedback, receiver_map,
3677 scratch1, scratch2);
3678 3672
3679 __ bind(&miss); 3673 __ bind(&miss);
3680 StoreIC::GenerateMiss(masm); 3674 StoreIC::GenerateMiss(masm);
3681 3675
3682 __ bind(&load_smi_map); 3676 __ bind(&load_smi_map);
3683 __ LoadRoot(receiver_map, Heap::kHeapNumberMapRootIndex); 3677 __ LoadRoot(receiver_map, Heap::kHeapNumberMapRootIndex);
3684 __ jmp(&compare_map); 3678 __ jmp(&compare_map);
3685 } 3679 }
3686 3680
3687 3681
(...skipping 1557 matching lines...) Expand 10 before | Expand all | Expand 10 after
5245 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref, 5239 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref,
5246 kStackUnwindSpace, NULL, return_value_operand, NULL); 5240 kStackUnwindSpace, NULL, return_value_operand, NULL);
5247 } 5241 }
5248 5242
5249 #undef __ 5243 #undef __
5250 5244
5251 } // namespace internal 5245 } // namespace internal
5252 } // namespace v8 5246 } // namespace v8
5253 5247
5254 #endif // V8_TARGET_ARCH_ARM 5248 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « no previous file | src/arm64/code-stubs-arm64.cc » ('j') | src/ic/x64/stub-cache-x64.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698