| Index: src/x64/lithium-codegen-x64.cc
|
| diff --git a/src/x64/lithium-codegen-x64.cc b/src/x64/lithium-codegen-x64.cc
|
| index b45917e82ffda33a5ead6a9af4774f8105f7ee7e..6305dc7587db4bfb3cc3afa0fce6435b7e126faf 100644
|
| --- a/src/x64/lithium-codegen-x64.cc
|
| +++ b/src/x64/lithium-codegen-x64.cc
|
| @@ -2890,6 +2890,22 @@ void LCodeGen::DoLoadGlobalGeneric(LLoadGlobalGeneric* instr) {
|
| }
|
|
|
|
|
| +void LCodeGen::DoLoadGlobalViaContext(LLoadGlobalViaContext* instr) {
|
| + DCHECK(ToRegister(instr->context()).is(rsi));
|
| + DCHECK(ToRegister(instr->result()).is(rax));
|
| +
|
| + __ Move(LoadGlobalViaContextDescriptor::DepthRegister(),
|
| + Smi::FromInt(instr->depth()));
|
| + __ Move(LoadGlobalViaContextDescriptor::SlotRegister(),
|
| + Smi::FromInt(instr->slot_index()));
|
| + __ Move(LoadGlobalViaContextDescriptor::NameRegister(), instr->name());
|
| +
|
| + Handle<Code> stub =
|
| + CodeFactory::LoadGlobalViaContext(isolate(), instr->depth()).code();
|
| + CallCode(stub, RelocInfo::CODE_TARGET, instr);
|
| +}
|
| +
|
| +
|
| void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) {
|
| Register context = ToRegister(instr->context());
|
| Register result = ToRegister(instr->result());
|
| @@ -4242,6 +4258,24 @@ void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) {
|
| }
|
|
|
|
|
| +void LCodeGen::DoStoreGlobalViaContext(LStoreGlobalViaContext* instr) {
|
| + DCHECK(ToRegister(instr->context()).is(rsi));
|
| + DCHECK(ToRegister(instr->value())
|
| + .is(StoreGlobalViaContextDescriptor::ValueRegister()));
|
| +
|
| + __ Move(StoreGlobalViaContextDescriptor::DepthRegister(),
|
| + Smi::FromInt(instr->depth()));
|
| + __ Move(StoreGlobalViaContextDescriptor::SlotRegister(),
|
| + Smi::FromInt(instr->slot_index()));
|
| + __ Move(StoreGlobalViaContextDescriptor::NameRegister(), instr->name());
|
| +
|
| + Handle<Code> stub =
|
| + CodeFactory::StoreGlobalViaContext(isolate(), instr->depth(),
|
| + instr->language_mode()).code();
|
| + CallCode(stub, RelocInfo::CODE_TARGET, instr);
|
| +}
|
| +
|
| +
|
| void LCodeGen::DoBoundsCheck(LBoundsCheck* instr) {
|
| Representation representation = instr->hydrogen()->length()->representation();
|
| DCHECK(representation.Equals(instr->hydrogen()->index()->representation()));
|
|
|