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

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

Issue 1227893005: TypeofMode replaces TypeofState and ContextualMode. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comments Created 5 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 | « src/arm64/lithium-arm64.h ('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 3344 matching lines...) Expand 10 before | Expand all | Expand 10 after
3355 } 3355 }
3356 3356
3357 3357
3358 void LCodeGen::DoLoadGlobalGeneric(LLoadGlobalGeneric* instr) { 3358 void LCodeGen::DoLoadGlobalGeneric(LLoadGlobalGeneric* instr) {
3359 DCHECK(ToRegister(instr->context()).is(cp)); 3359 DCHECK(ToRegister(instr->context()).is(cp));
3360 DCHECK(ToRegister(instr->global_object()) 3360 DCHECK(ToRegister(instr->global_object())
3361 .is(LoadDescriptor::ReceiverRegister())); 3361 .is(LoadDescriptor::ReceiverRegister()));
3362 DCHECK(ToRegister(instr->result()).Is(x0)); 3362 DCHECK(ToRegister(instr->result()).Is(x0));
3363 __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name())); 3363 __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name()));
3364 EmitVectorLoadICRegisters<LLoadGlobalGeneric>(instr); 3364 EmitVectorLoadICRegisters<LLoadGlobalGeneric>(instr);
3365 ContextualMode mode = instr->for_typeof() ? NOT_CONTEXTUAL : CONTEXTUAL; 3365 Handle<Code> ic =
3366 Handle<Code> ic = CodeFactory::LoadICInOptimizedCode(isolate(), mode, SLOPPY, 3366 CodeFactory::LoadICInOptimizedCode(isolate(), instr->typeof_mode(),
3367 PREMONOMORPHIC).code(); 3367 SLOPPY, PREMONOMORPHIC).code();
3368 CallCode(ic, RelocInfo::CODE_TARGET, instr); 3368 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3369 } 3369 }
3370 3370
3371 3371
3372 MemOperand LCodeGen::PrepareKeyedExternalArrayOperand( 3372 MemOperand LCodeGen::PrepareKeyedExternalArrayOperand(
3373 Register key, 3373 Register key,
3374 Register base, 3374 Register base,
3375 Register scratch, 3375 Register scratch,
3376 bool key_is_smi, 3376 bool key_is_smi,
3377 bool key_is_constant, 3377 bool key_is_constant,
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
3685 3685
3686 3686
3687 void LCodeGen::DoLoadNamedGeneric(LLoadNamedGeneric* instr) { 3687 void LCodeGen::DoLoadNamedGeneric(LLoadNamedGeneric* instr) {
3688 DCHECK(ToRegister(instr->context()).is(cp)); 3688 DCHECK(ToRegister(instr->context()).is(cp));
3689 // LoadIC expects name and receiver in registers. 3689 // LoadIC expects name and receiver in registers.
3690 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); 3690 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister()));
3691 __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name())); 3691 __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name()));
3692 EmitVectorLoadICRegisters<LLoadNamedGeneric>(instr); 3692 EmitVectorLoadICRegisters<LLoadNamedGeneric>(instr);
3693 Handle<Code> ic = 3693 Handle<Code> ic =
3694 CodeFactory::LoadICInOptimizedCode( 3694 CodeFactory::LoadICInOptimizedCode(
3695 isolate(), NOT_CONTEXTUAL, instr->hydrogen()->language_mode(), 3695 isolate(), NOT_INSIDE_TYPEOF, instr->hydrogen()->language_mode(),
3696 instr->hydrogen()->initialization_state()).code(); 3696 instr->hydrogen()->initialization_state()).code();
3697 CallCode(ic, RelocInfo::CODE_TARGET, instr); 3697 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3698 3698
3699 DCHECK(ToRegister(instr->result()).is(x0)); 3699 DCHECK(ToRegister(instr->result()).is(x0));
3700 } 3700 }
3701 3701
3702 3702
3703 void LCodeGen::DoLoadRoot(LLoadRoot* instr) { 3703 void LCodeGen::DoLoadRoot(LLoadRoot* instr) {
3704 Register result = ToRegister(instr->result()); 3704 Register result = ToRegister(instr->result());
3705 __ LoadRoot(result, instr->index()); 3705 __ LoadRoot(result, instr->index());
(...skipping 2410 matching lines...) Expand 10 before | Expand all | Expand 10 after
6116 Handle<ScopeInfo> scope_info = instr->scope_info(); 6116 Handle<ScopeInfo> scope_info = instr->scope_info();
6117 __ Push(scope_info); 6117 __ Push(scope_info);
6118 __ Push(ToRegister(instr->function())); 6118 __ Push(ToRegister(instr->function()));
6119 CallRuntime(Runtime::kPushBlockContext, 2, instr); 6119 CallRuntime(Runtime::kPushBlockContext, 2, instr);
6120 RecordSafepoint(Safepoint::kNoLazyDeopt); 6120 RecordSafepoint(Safepoint::kNoLazyDeopt);
6121 } 6121 }
6122 6122
6123 6123
6124 } // namespace internal 6124 } // namespace internal
6125 } // namespace v8 6125 } // namespace v8
OLDNEW
« no previous file with comments | « src/arm64/lithium-arm64.h ('k') | src/code-factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698