summaryrefslogtreecommitdiff
path: root/src/3rdparty/v8/src/mips/code-stubs-mips.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/v8/src/mips/code-stubs-mips.cc')
-rw-r--r--src/3rdparty/v8/src/mips/code-stubs-mips.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/3rdparty/v8/src/mips/code-stubs-mips.cc b/src/3rdparty/v8/src/mips/code-stubs-mips.cc
index 7f7d70e..f122d14 100644
--- a/src/3rdparty/v8/src/mips/code-stubs-mips.cc
+++ b/src/3rdparty/v8/src/mips/code-stubs-mips.cc
@@ -251,6 +251,11 @@ void FastNewContextStub::Generate(MacroAssembler* masm) {
__ sw(a1, MemOperand(v0, Context::SlotOffset(Context::EXTENSION_INDEX)));
__ sw(a2, MemOperand(v0, Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX)));
+ // Copy the qml global object from the surrounding context.
+ __ lw(a1, MemOperand(cp, Context::SlotOffset(Context::QML_GLOBAL_OBJECT_INDEX)));
+ __ sw(a1, MemOperand(v0, Context::SlotOffset(Context::QML_GLOBAL_OBJECT_INDEX)));
+
+
// Initialize the rest of the slots to undefined.
__ LoadRoot(a1, Heap::kUndefinedValueRootIndex);
for (int i = Context::MIN_CONTEXT_SLOTS; i < length; i++) {
@@ -313,6 +318,10 @@ void FastNewBlockContextStub::Generate(MacroAssembler* masm) {
__ sw(a1, ContextOperand(v0, Context::EXTENSION_INDEX));
__ sw(a2, ContextOperand(v0, Context::GLOBAL_OBJECT_INDEX));
+ // Copy the qml global object from the surrounding context.
+ __ lw(a1, ContextOperand(cp, Context::QML_GLOBAL_OBJECT_INDEX));
+ __ sw(a1, ContextOperand(v0, Context::QML_GLOBAL_OBJECT_INDEX));
+
// Initialize the rest of the slots to the hole value.
__ LoadRoot(a1, Heap::kTheHoleValueRootIndex);
for (int i = 0; i < slots_; i++) {