MIPS: Check for function in %_CallFunction.
Port r12299 (f6372257) BUG= TEST= Review URL: https://chromiumcodereview.appspot.com/10834317 Patch from Akos Palfi <palfia@homejinni.com>. git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12316 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
886c0fa4f7
commit
8607093fab
@ -3460,10 +3460,11 @@ void FullCodeGenerator::EmitCallFunction(CallRuntime* expr) {
|
||||
}
|
||||
VisitForAccumulatorValue(args->last()); // Function.
|
||||
|
||||
// Check for proxy.
|
||||
Label proxy, done;
|
||||
Label runtime, done;
|
||||
// Check for non-function argument (including proxy).
|
||||
__ JumpIfSmi(v0, &runtime);
|
||||
__ GetObjectType(v0, a1, a1);
|
||||
__ Branch(&proxy, eq, a1, Operand(JS_FUNCTION_PROXY_TYPE));
|
||||
__ Branch(&runtime, ne, a1, Operand(JS_FUNCTION_TYPE));
|
||||
|
||||
// InvokeFunction requires the function in a1. Move it in there.
|
||||
__ mov(a1, result_register());
|
||||
@ -3473,7 +3474,7 @@ void FullCodeGenerator::EmitCallFunction(CallRuntime* expr) {
|
||||
__ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
|
||||
__ jmp(&done);
|
||||
|
||||
__ bind(&proxy);
|
||||
__ bind(&runtime);
|
||||
__ push(v0);
|
||||
__ CallRuntime(Runtime::kCall, args->length());
|
||||
__ bind(&done);
|
||||
|
Loading…
Reference in New Issue
Block a user