Port the function prototype load stub to ARM.
Review URL: http://codereview.chromium.org/155373 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2430 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
00cdc3f1a3
commit
55050383e1
@ -192,11 +192,14 @@ void LoadIC::GenerateFunctionPrototype(MacroAssembler* masm) {
|
||||
// -- [sp] : receiver
|
||||
// -----------------------------------
|
||||
|
||||
// NOTE: Right now, this code always misses on ARM which is
|
||||
// sub-optimal. We should port the fast case code from IA-32.
|
||||
Label miss;
|
||||
|
||||
Handle<Code> ic(Builtins::builtin(Builtins::LoadIC_Miss));
|
||||
__ Jump(ic, RelocInfo::CODE_TARGET);
|
||||
// Load receiver.
|
||||
__ ldr(r0, MemOperand(sp, 0));
|
||||
|
||||
StubCompiler::GenerateLoadFunctionPrototype(masm, r0, r1, r3, &miss);
|
||||
__ bind(&miss);
|
||||
StubCompiler::GenerateLoadMiss(masm, Code::LOAD_IC);
|
||||
}
|
||||
|
||||
|
||||
|
@ -247,6 +247,17 @@ void StubCompiler::GenerateLoadStringLength2(MacroAssembler* masm,
|
||||
}
|
||||
|
||||
|
||||
void StubCompiler::GenerateLoadFunctionPrototype(MacroAssembler* masm,
|
||||
Register receiver,
|
||||
Register scratch1,
|
||||
Register scratch2,
|
||||
Label* miss_label) {
|
||||
__ TryGetFunctionPrototype(receiver, scratch1, scratch2, miss_label);
|
||||
__ mov(r0, scratch1);
|
||||
__ Ret();
|
||||
}
|
||||
|
||||
|
||||
// Generate StoreField code, value is passed in r0 register.
|
||||
// After executing generated code, the receiver_reg and name_reg
|
||||
// may be clobbered.
|
||||
|
Loading…
Reference in New Issue
Block a user