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

Side by Side Diff: src/arm64/lithium-codegen-arm64.cc

Issue 945313003: emit premonomorphic ics for keyed loads/stores in optimized code (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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 | « src/arm/lithium-codegen-arm.cc ('k') | src/code-factory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/arm64/lithium-codegen-arm64.h" 7 #include "src/arm64/lithium-codegen-arm64.h"
8 #include "src/arm64/lithium-gap-resolver-arm64.h" 8 #include "src/arm64/lithium-gap-resolver-arm64.h"
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 3679 matching lines...) Expand 10 before | Expand all | Expand 10 after
3690 3690
3691 3691
3692 void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) { 3692 void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) {
3693 DCHECK(ToRegister(instr->context()).is(cp)); 3693 DCHECK(ToRegister(instr->context()).is(cp));
3694 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); 3694 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister()));
3695 DCHECK(ToRegister(instr->key()).is(LoadDescriptor::NameRegister())); 3695 DCHECK(ToRegister(instr->key()).is(LoadDescriptor::NameRegister()));
3696 if (FLAG_vector_ics) { 3696 if (FLAG_vector_ics) {
3697 EmitVectorLoadICRegisters<LLoadKeyedGeneric>(instr); 3697 EmitVectorLoadICRegisters<LLoadKeyedGeneric>(instr);
3698 } 3698 }
3699 3699
3700 Handle<Code> ic = CodeFactory::KeyedLoadICInOptimizedCode(isolate()).code(); 3700 Handle<Code> ic =
3701 CodeFactory::KeyedLoadICInOptimizedCode(
3702 isolate(), instr->hydrogen()->initialization_state()).code();
3701 CallCode(ic, RelocInfo::CODE_TARGET, instr); 3703 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3702 3704
3703 DCHECK(ToRegister(instr->result()).Is(x0)); 3705 DCHECK(ToRegister(instr->result()).Is(x0));
3704 } 3706 }
3705 3707
3706 3708
3707 void LCodeGen::DoLoadNamedField(LLoadNamedField* instr) { 3709 void LCodeGen::DoLoadNamedField(LLoadNamedField* instr) {
3708 HObjectAccess access = instr->hydrogen()->access(); 3710 HObjectAccess access = instr->hydrogen()->access();
3709 int offset = access.offset(); 3711 int offset = access.offset();
3710 Register object = ToRegister(instr->object()); 3712 Register object = ToRegister(instr->object());
(...skipping 1668 matching lines...) Expand 10 before | Expand all | Expand 10 after
5379 } 5381 }
5380 } 5382 }
5381 5383
5382 5384
5383 void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) { 5385 void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) {
5384 DCHECK(ToRegister(instr->context()).is(cp)); 5386 DCHECK(ToRegister(instr->context()).is(cp));
5385 DCHECK(ToRegister(instr->object()).is(StoreDescriptor::ReceiverRegister())); 5387 DCHECK(ToRegister(instr->object()).is(StoreDescriptor::ReceiverRegister()));
5386 DCHECK(ToRegister(instr->key()).is(StoreDescriptor::NameRegister())); 5388 DCHECK(ToRegister(instr->key()).is(StoreDescriptor::NameRegister()));
5387 DCHECK(ToRegister(instr->value()).is(StoreDescriptor::ValueRegister())); 5389 DCHECK(ToRegister(instr->value()).is(StoreDescriptor::ValueRegister()));
5388 5390
5389 Handle<Code> ic = 5391 Handle<Code> ic = CodeFactory::KeyedStoreICInOptimizedCode(
5390 CodeFactory::KeyedStoreIC(isolate(), instr->language_mode()).code(); 5392 isolate(), instr->language_mode(),
5393 instr->hydrogen()->initialization_state()).code();
5391 CallCode(ic, RelocInfo::CODE_TARGET, instr); 5394 CallCode(ic, RelocInfo::CODE_TARGET, instr);
5392 } 5395 }
5393 5396
5394 5397
5395 void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) { 5398 void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
5396 Representation representation = instr->representation(); 5399 Representation representation = instr->representation();
5397 5400
5398 Register object = ToRegister(instr->object()); 5401 Register object = ToRegister(instr->object());
5399 HObjectAccess access = instr->hydrogen()->access(); 5402 HObjectAccess access = instr->hydrogen()->access();
5400 int offset = access.offset(); 5403 int offset = access.offset();
(...skipping 703 matching lines...) Expand 10 before | Expand all | Expand 10 after
6104 Handle<ScopeInfo> scope_info = instr->scope_info(); 6107 Handle<ScopeInfo> scope_info = instr->scope_info();
6105 __ Push(scope_info); 6108 __ Push(scope_info);
6106 __ Push(ToRegister(instr->function())); 6109 __ Push(ToRegister(instr->function()));
6107 CallRuntime(Runtime::kPushBlockContext, 2, instr); 6110 CallRuntime(Runtime::kPushBlockContext, 2, instr);
6108 RecordSafepoint(Safepoint::kNoLazyDeopt); 6111 RecordSafepoint(Safepoint::kNoLazyDeopt);
6109 } 6112 }
6110 6113
6111 6114
6112 6115
6113 } } // namespace v8::internal 6116 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/code-factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698