Chromium Code Reviews| Index: src/stub-cache.cc |
| diff --git a/src/stub-cache.cc b/src/stub-cache.cc |
| index a562ace477a66ae99fc8d5cd638ebbad8817791e..23426384e8a21395a69adebf710abfed3f1ad8dc 100644 |
| --- a/src/stub-cache.cc |
| +++ b/src/stub-cache.cc |
| @@ -1149,9 +1149,19 @@ void CallStubCompiler::GenerateJumpFunctionIgnoreReceiver( |
| } |
| +void CallStubCompiler::PatchGlobalProxy(Handle<Object> object, |
| + Register function) { |
| + if (object->IsGlobalObject()) { |
| + FetchGlobalProxy(masm(), function, rdx); |
|
Toon Verwaest
2013/12/18 13:09:33
EEK! rdx in src/stub-cache.cc?
Please run tests o
|
| + StackArgumentsAccessor args(rsp, arguments().immediate()); |
| + __ movq(args.GetReceiverOperand(), rdx); |
| + } |
| +} |
| + |
| + |
| void CallStubCompiler::GenerateJumpFunction(Handle<Object> object, |
| Handle<JSFunction> function) { |
| - PatchGlobalProxy(object); |
| + PatchGlobalProxy(object, function); |
| GenerateJumpFunctionIgnoreReceiver(function); |
| } |
| @@ -1159,7 +1169,7 @@ void CallStubCompiler::GenerateJumpFunction(Handle<Object> object, |
| void CallStubCompiler::GenerateJumpFunction(Handle<Object> object, |
| Register actual_closure, |
| Handle<JSFunction> function) { |
| - PatchGlobalProxy(object); |
| + PatchGlobalProxy(object, function); |
| ParameterCount expected(function); |
| __ InvokeFunction(actual_closure, expected, arguments(), |
| JUMP_FUNCTION, NullCallWrapper(), call_kind()); |