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

Side by Side Diff: src/mips64/lithium-codegen-mips64.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/mips/lithium-codegen-mips.cc ('k') | src/x64/lithium-codegen-x64.cc » ('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 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 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/cpu-profiler.h" 9 #include "src/cpu-profiler.h"
10 #include "src/hydrogen-osr.h" 10 #include "src/hydrogen-osr.h"
(...skipping 3391 matching lines...) Expand 10 before | Expand all | Expand 10 after
3402 3402
3403 void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) { 3403 void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) {
3404 DCHECK(ToRegister(instr->context()).is(cp)); 3404 DCHECK(ToRegister(instr->context()).is(cp));
3405 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); 3405 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister()));
3406 DCHECK(ToRegister(instr->key()).is(LoadDescriptor::NameRegister())); 3406 DCHECK(ToRegister(instr->key()).is(LoadDescriptor::NameRegister()));
3407 3407
3408 if (FLAG_vector_ics) { 3408 if (FLAG_vector_ics) {
3409 EmitVectorLoadICRegisters<LLoadKeyedGeneric>(instr); 3409 EmitVectorLoadICRegisters<LLoadKeyedGeneric>(instr);
3410 } 3410 }
3411 3411
3412 Handle<Code> ic = CodeFactory::KeyedLoadICInOptimizedCode(isolate()).code(); 3412 Handle<Code> ic =
3413 CodeFactory::KeyedLoadICInOptimizedCode(
3414 isolate(), instr->hydrogen()->initialization_state()).code();
3413 CallCode(ic, RelocInfo::CODE_TARGET, instr); 3415 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3414 } 3416 }
3415 3417
3416 3418
3417 void LCodeGen::DoArgumentsElements(LArgumentsElements* instr) { 3419 void LCodeGen::DoArgumentsElements(LArgumentsElements* instr) {
3418 Register scratch = scratch0(); 3420 Register scratch = scratch0();
3419 Register temp = scratch1(); 3421 Register temp = scratch1();
3420 Register result = ToRegister(instr->result()); 3422 Register result = ToRegister(instr->result());
3421 3423
3422 if (instr->hydrogen()->from_inlined()) { 3424 if (instr->hydrogen()->from_inlined()) {
(...skipping 1142 matching lines...) Expand 10 before | Expand all | Expand 10 after
4565 } 4567 }
4566 } 4568 }
4567 4569
4568 4570
4569 void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) { 4571 void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) {
4570 DCHECK(ToRegister(instr->context()).is(cp)); 4572 DCHECK(ToRegister(instr->context()).is(cp));
4571 DCHECK(ToRegister(instr->object()).is(StoreDescriptor::ReceiverRegister())); 4573 DCHECK(ToRegister(instr->object()).is(StoreDescriptor::ReceiverRegister()));
4572 DCHECK(ToRegister(instr->key()).is(StoreDescriptor::NameRegister())); 4574 DCHECK(ToRegister(instr->key()).is(StoreDescriptor::NameRegister()));
4573 DCHECK(ToRegister(instr->value()).is(StoreDescriptor::ValueRegister())); 4575 DCHECK(ToRegister(instr->value()).is(StoreDescriptor::ValueRegister()));
4574 4576
4575 Handle<Code> ic = 4577 Handle<Code> ic = CodeFactory::KeyedStoreICInOptimizedCode(
4576 CodeFactory::KeyedStoreIC(isolate(), instr->language_mode()).code(); 4578 isolate(), instr->language_mode(),
4579 instr->hydrogen()->initialization_state()).code();
4577 CallCode(ic, RelocInfo::CODE_TARGET, instr); 4580 CallCode(ic, RelocInfo::CODE_TARGET, instr);
4578 } 4581 }
4579 4582
4580 4583
4581 void LCodeGen::DoTransitionElementsKind(LTransitionElementsKind* instr) { 4584 void LCodeGen::DoTransitionElementsKind(LTransitionElementsKind* instr) {
4582 Register object_reg = ToRegister(instr->object()); 4585 Register object_reg = ToRegister(instr->object());
4583 Register scratch = scratch0(); 4586 Register scratch = scratch0();
4584 4587
4585 Handle<Map> from_map = instr->original_map(); 4588 Handle<Map> from_map = instr->original_map();
4586 Handle<Map> to_map = instr->transitioned_map(); 4589 Handle<Map> to_map = instr->transitioned_map();
(...skipping 1466 matching lines...) Expand 10 before | Expand all | Expand 10 after
6053 __ li(at, scope_info); 6056 __ li(at, scope_info);
6054 __ Push(at, ToRegister(instr->function())); 6057 __ Push(at, ToRegister(instr->function()));
6055 CallRuntime(Runtime::kPushBlockContext, 2, instr); 6058 CallRuntime(Runtime::kPushBlockContext, 2, instr);
6056 RecordSafepoint(Safepoint::kNoLazyDeopt); 6059 RecordSafepoint(Safepoint::kNoLazyDeopt);
6057 } 6060 }
6058 6061
6059 6062
6060 #undef __ 6063 #undef __
6061 6064
6062 } } // namespace v8::internal 6065 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/mips/lithium-codegen-mips.cc ('k') | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698