Fix constant function transition. Insert return instruction before returning.

R=jkummerow@chromium.org

Review URL: https://chromiumcodereview.appspot.com/17250003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15180 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
verwaest@chromium.org 2013-06-17 13:50:56 +00:00
parent 5fe01da568
commit 202df2e758
3 changed files with 15 additions and 3 deletions

View File

@ -577,7 +577,11 @@ void StubCompiler::GenerateStoreTransition(MacroAssembler* masm,
OMIT_REMEMBERED_SET,
OMIT_SMI_CHECK);
if (details.type() == CONSTANT_FUNCTION) return;
if (details.type() == CONSTANT_FUNCTION) {
ASSERT(value_reg.is(r0));
__ Ret();
return;
}
int index = transition->instance_descriptors()->GetFieldIndex(
transition->LastAdded());

View File

@ -931,7 +931,11 @@ void StubCompiler::GenerateStoreTransition(MacroAssembler* masm,
OMIT_REMEMBERED_SET,
OMIT_SMI_CHECK);
if (details.type() == CONSTANT_FUNCTION) return;
if (details.type() == CONSTANT_FUNCTION) {
ASSERT(value_reg.is(eax));
__ ret(0);
return;
}
int index = transition->instance_descriptors()->GetFieldIndex(
transition->LastAdded());

View File

@ -889,7 +889,11 @@ void StubCompiler::GenerateStoreTransition(MacroAssembler* masm,
OMIT_REMEMBERED_SET,
OMIT_SMI_CHECK);
if (details.type() == CONSTANT_FUNCTION) return;
if (details.type() == CONSTANT_FUNCTION) {
ASSERT(value_reg.is(rax));
__ ret(0);
return;
}
int index = transition->instance_descriptors()->GetFieldIndex(
transition->LastAdded());