| 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 #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 3373 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 3384 void LCodeGen::DoLoadGlobalGeneric(LLoadGlobalGeneric* instr) { | 3384 void LCodeGen::DoLoadGlobalGeneric(LLoadGlobalGeneric* instr) { | 
| 3385   DCHECK(ToRegister(instr->context()).is(cp)); | 3385   DCHECK(ToRegister(instr->context()).is(cp)); | 
| 3386   DCHECK(ToRegister(instr->global_object()) | 3386   DCHECK(ToRegister(instr->global_object()) | 
| 3387              .is(LoadDescriptor::ReceiverRegister())); | 3387              .is(LoadDescriptor::ReceiverRegister())); | 
| 3388   DCHECK(ToRegister(instr->result()).Is(x0)); | 3388   DCHECK(ToRegister(instr->result()).Is(x0)); | 
| 3389   __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name())); | 3389   __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name())); | 
| 3390   if (FLAG_vector_ics) { | 3390   if (FLAG_vector_ics) { | 
| 3391     EmitVectorLoadICRegisters<LLoadGlobalGeneric>(instr); | 3391     EmitVectorLoadICRegisters<LLoadGlobalGeneric>(instr); | 
| 3392   } | 3392   } | 
| 3393   ContextualMode mode = instr->for_typeof() ? NOT_CONTEXTUAL : CONTEXTUAL; | 3393   ContextualMode mode = instr->for_typeof() ? NOT_CONTEXTUAL : CONTEXTUAL; | 
| 3394   Handle<Code> ic = CodeFactory::LoadIC(isolate(), mode).code(); | 3394   Handle<Code> ic = CodeFactory::LoadICInOptimizedCode(isolate(), mode).code(); | 
| 3395   CallCode(ic, RelocInfo::CODE_TARGET, instr); | 3395   CallCode(ic, RelocInfo::CODE_TARGET, instr); | 
| 3396 } | 3396 } | 
| 3397 | 3397 | 
| 3398 | 3398 | 
| 3399 MemOperand LCodeGen::PrepareKeyedExternalArrayOperand( | 3399 MemOperand LCodeGen::PrepareKeyedExternalArrayOperand( | 
| 3400     Register key, | 3400     Register key, | 
| 3401     Register base, | 3401     Register base, | 
| 3402     Register scratch, | 3402     Register scratch, | 
| 3403     bool key_is_smi, | 3403     bool key_is_smi, | 
| 3404     bool key_is_constant, | 3404     bool key_is_constant, | 
| (...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 3638 | 3638 | 
| 3639 | 3639 | 
| 3640 void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) { | 3640 void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) { | 
| 3641   DCHECK(ToRegister(instr->context()).is(cp)); | 3641   DCHECK(ToRegister(instr->context()).is(cp)); | 
| 3642   DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); | 3642   DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); | 
| 3643   DCHECK(ToRegister(instr->key()).is(LoadDescriptor::NameRegister())); | 3643   DCHECK(ToRegister(instr->key()).is(LoadDescriptor::NameRegister())); | 
| 3644   if (FLAG_vector_ics) { | 3644   if (FLAG_vector_ics) { | 
| 3645     EmitVectorLoadICRegisters<LLoadKeyedGeneric>(instr); | 3645     EmitVectorLoadICRegisters<LLoadKeyedGeneric>(instr); | 
| 3646   } | 3646   } | 
| 3647 | 3647 | 
| 3648   Handle<Code> ic = CodeFactory::KeyedLoadIC(isolate()).code(); | 3648   Handle<Code> ic = CodeFactory::KeyedLoadICInOptimizedCode(isolate()).code(); | 
| 3649   CallCode(ic, RelocInfo::CODE_TARGET, instr); | 3649   CallCode(ic, RelocInfo::CODE_TARGET, instr); | 
| 3650 | 3650 | 
| 3651   DCHECK(ToRegister(instr->result()).Is(x0)); | 3651   DCHECK(ToRegister(instr->result()).Is(x0)); | 
| 3652 } | 3652 } | 
| 3653 | 3653 | 
| 3654 | 3654 | 
| 3655 void LCodeGen::DoLoadNamedField(LLoadNamedField* instr) { | 3655 void LCodeGen::DoLoadNamedField(LLoadNamedField* instr) { | 
| 3656   HObjectAccess access = instr->hydrogen()->access(); | 3656   HObjectAccess access = instr->hydrogen()->access(); | 
| 3657   int offset = access.offset(); | 3657   int offset = access.offset(); | 
| 3658   Register object = ToRegister(instr->object()); | 3658   Register object = ToRegister(instr->object()); | 
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 3694 | 3694 | 
| 3695 void LCodeGen::DoLoadNamedGeneric(LLoadNamedGeneric* instr) { | 3695 void LCodeGen::DoLoadNamedGeneric(LLoadNamedGeneric* instr) { | 
| 3696   DCHECK(ToRegister(instr->context()).is(cp)); | 3696   DCHECK(ToRegister(instr->context()).is(cp)); | 
| 3697   // LoadIC expects name and receiver in registers. | 3697   // LoadIC expects name and receiver in registers. | 
| 3698   DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); | 3698   DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister())); | 
| 3699   __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name())); | 3699   __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name())); | 
| 3700   if (FLAG_vector_ics) { | 3700   if (FLAG_vector_ics) { | 
| 3701     EmitVectorLoadICRegisters<LLoadNamedGeneric>(instr); | 3701     EmitVectorLoadICRegisters<LLoadNamedGeneric>(instr); | 
| 3702   } | 3702   } | 
| 3703 | 3703 | 
| 3704   Handle<Code> ic = CodeFactory::LoadIC(isolate(), NOT_CONTEXTUAL).code(); | 3704   Handle<Code> ic = | 
|  | 3705       CodeFactory::LoadICInOptimizedCode(isolate(), NOT_CONTEXTUAL).code(); | 
| 3705   CallCode(ic, RelocInfo::CODE_TARGET, instr); | 3706   CallCode(ic, RelocInfo::CODE_TARGET, instr); | 
| 3706 | 3707 | 
| 3707   DCHECK(ToRegister(instr->result()).is(x0)); | 3708   DCHECK(ToRegister(instr->result()).is(x0)); | 
| 3708 } | 3709 } | 
| 3709 | 3710 | 
| 3710 | 3711 | 
| 3711 void LCodeGen::DoLoadRoot(LLoadRoot* instr) { | 3712 void LCodeGen::DoLoadRoot(LLoadRoot* instr) { | 
| 3712   Register result = ToRegister(instr->result()); | 3713   Register result = ToRegister(instr->result()); | 
| 3713   __ LoadRoot(result, instr->index()); | 3714   __ LoadRoot(result, instr->index()); | 
| 3714 } | 3715 } | 
| (...skipping 2324 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 6039   Handle<ScopeInfo> scope_info = instr->scope_info(); | 6040   Handle<ScopeInfo> scope_info = instr->scope_info(); | 
| 6040   __ Push(scope_info); | 6041   __ Push(scope_info); | 
| 6041   __ Push(ToRegister(instr->function())); | 6042   __ Push(ToRegister(instr->function())); | 
| 6042   CallRuntime(Runtime::kPushBlockContext, 2, instr); | 6043   CallRuntime(Runtime::kPushBlockContext, 2, instr); | 
| 6043   RecordSafepoint(Safepoint::kNoLazyDeopt); | 6044   RecordSafepoint(Safepoint::kNoLazyDeopt); | 
| 6044 } | 6045 } | 
| 6045 | 6046 | 
| 6046 | 6047 | 
| 6047 | 6048 | 
| 6048 } }  // namespace v8::internal | 6049 } }  // namespace v8::internal | 
| OLD | NEW | 
|---|