| Index: src/mips/lithium-codegen-mips.cc
|
| diff --git a/src/mips/lithium-codegen-mips.cc b/src/mips/lithium-codegen-mips.cc
|
| index 7f314226e0b944edc13f7113e6740187e6d710d8..3cedd7e54a2da1f05abbe3abb8f14acf6549b5d8 100644
|
| --- a/src/mips/lithium-codegen-mips.cc
|
| +++ b/src/mips/lithium-codegen-mips.cc
|
| @@ -200,7 +200,11 @@ bool LCodeGen::GeneratePrologue() {
|
| Comment(";;; Allocate local context");
|
| bool need_write_barrier = true;
|
| // Argument to NewContext is the function, which is in a1.
|
| - if (heap_slots <= FastNewContextStub::kMaximumSlots) {
|
| + if (FLAG_harmony_scoping && info()->scope()->is_global_scope()) {
|
| + __ push(a1);
|
| + __ Push(info()->scope()->GetScopeInfo());
|
| + __ CallRuntime(Runtime::kNewGlobalContext, 2);
|
| + } else if (heap_slots <= FastNewContextStub::kMaximumSlots) {
|
| FastNewContextStub stub(isolate(), heap_slots);
|
| __ CallStub(&stub);
|
| // Result of FastNewContextStub is always in new space.
|
|
|