Commit 08f00a15 authored by zhengxing.li's avatar zhengxing.li Committed by Commit bot

X87: [builtins] More stubs to the builtin-o-sphere.

  port 05873add (r41989)

  original commit message:
  The following ported to builtins:
  FastCloneRegExp
  FastCloneShallowArray
  FastCloneShallowObject

BUG=

Review-Url: https://codereview.chromium.org/2607383002
Cr-Commit-Position: refs/heads/master@{#42020}
parent 6ef22472
...@@ -1141,8 +1141,9 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) { ...@@ -1141,8 +1141,9 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) {
__ mov(ebx, Immediate(Smi::FromInt(expr->literal_index()))); __ mov(ebx, Immediate(Smi::FromInt(expr->literal_index())));
__ mov(ecx, Immediate(constant_properties)); __ mov(ecx, Immediate(constant_properties));
__ mov(edx, Immediate(Smi::FromInt(flags))); __ mov(edx, Immediate(Smi::FromInt(flags)));
FastCloneShallowObjectStub stub(isolate(), expr->properties_count()); Callable callable = CodeFactory::FastCloneShallowObject(
__ CallStub(&stub); isolate(), expr->properties_count());
__ Call(callable.code(), RelocInfo::CODE_TARGET);
RestoreContext(); RestoreContext();
} }
PrepareForBailoutForId(expr->CreateLiteralId(), BailoutState::TOS_REGISTER); PrepareForBailoutForId(expr->CreateLiteralId(), BailoutState::TOS_REGISTER);
...@@ -1274,8 +1275,9 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) { ...@@ -1274,8 +1275,9 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) {
__ mov(eax, Operand(ebp, JavaScriptFrameConstants::kFunctionOffset)); __ mov(eax, Operand(ebp, JavaScriptFrameConstants::kFunctionOffset));
__ mov(ebx, Immediate(Smi::FromInt(expr->literal_index()))); __ mov(ebx, Immediate(Smi::FromInt(expr->literal_index())));
__ mov(ecx, Immediate(constant_elements)); __ mov(ecx, Immediate(constant_elements));
FastCloneShallowArrayStub stub(isolate(), allocation_site_mode); Callable callable =
__ CallStub(&stub); CodeFactory::FastCloneShallowArray(isolate(), allocation_site_mode);
__ Call(callable.code(), RelocInfo::CODE_TARGET);
RestoreContext(); RestoreContext();
} }
PrepareForBailoutForId(expr->CreateLiteralId(), BailoutState::TOS_REGISTER); PrepareForBailoutForId(expr->CreateLiteralId(), BailoutState::TOS_REGISTER);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment