Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(240)

Unified Diff: src/full-codegen/x64/full-codegen-x64.cc

Issue 1517243002: [es6] Remove the %DefaultConstructorCallSuper intrinsic. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@GetSuperConstructor
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/full-codegen/ppc/full-codegen-ppc.cc ('k') | src/full-codegen/x87/full-codegen-x87.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/full-codegen/x64/full-codegen-x64.cc
diff --git a/src/full-codegen/x64/full-codegen-x64.cc b/src/full-codegen/x64/full-codegen-x64.cc
index 961cefa4f52404982174e120bc40ede50f7e1538..dc1354b3ce37ce43ffae46f6369016c1f5c28bc9 100644
--- a/src/full-codegen/x64/full-codegen-x64.cc
+++ b/src/full-codegen/x64/full-codegen-x64.cc
@@ -3603,57 +3603,6 @@ void FullCodeGenerator::EmitCall(CallRuntime* expr) {
}
-void FullCodeGenerator::EmitDefaultConstructorCallSuper(CallRuntime* expr) {
- ZoneList<Expression*>* args = expr->arguments();
- DCHECK(args->length() == 2);
-
- // Evaluate new.target and super constructor.
- VisitForStackValue(args->at(0));
- VisitForStackValue(args->at(1));
-
- // Call the construct call builtin that handles allocation and
- // constructor invocation.
- SetConstructCallPosition(expr);
-
- // Check if the calling frame is an arguments adaptor frame.
- Label adaptor_frame, args_set_up, runtime;
- __ movp(rdx, Operand(rbp, StandardFrameConstants::kCallerFPOffset));
- __ movp(rbx, Operand(rdx, StandardFrameConstants::kContextOffset));
- __ Cmp(rbx, Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR));
- __ j(equal, &adaptor_frame);
- // default constructor has no arguments, so no adaptor frame means no args.
- __ movp(rax, Immediate(0));
- __ jmp(&args_set_up);
-
- // Copy arguments from adaptor frame.
- {
- __ bind(&adaptor_frame);
- __ movp(rbx, Operand(rdx, ArgumentsAdaptorFrameConstants::kLengthOffset));
- __ SmiToInteger64(rbx, rbx);
-
- __ movp(rax, rbx);
- __ leap(rdx, Operand(rdx, rbx, times_pointer_size,
- StandardFrameConstants::kCallerSPOffset));
- Label loop;
- __ bind(&loop);
- __ Push(Operand(rdx, -1 * kPointerSize));
- __ subp(rdx, Immediate(kPointerSize));
- __ decp(rbx);
- __ j(not_zero, &loop);
- }
-
- __ bind(&args_set_up);
- __ movp(rdx, Operand(rsp, rax, times_pointer_size, 1 * kPointerSize));
- __ movp(rdi, Operand(rsp, rax, times_pointer_size, 0 * kPointerSize));
- __ Call(isolate()->builtins()->Construct(), RelocInfo::CODE_TARGET);
-
- // Restore context register.
- __ movp(rsi, Operand(rbp, StandardFrameConstants::kContextOffset));
-
- context()->DropAndPlug(1, rax);
-}
-
-
void FullCodeGenerator::EmitHasCachedArrayIndex(CallRuntime* expr) {
ZoneList<Expression*>* args = expr->arguments();
DCHECK(args->length() == 1);
« no previous file with comments | « src/full-codegen/ppc/full-codegen-ppc.cc ('k') | src/full-codegen/x87/full-codegen-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698