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

Side by Side Diff: src/full-codegen/mips64/full-codegen-mips64.cc

Issue 1321343004: Desugar %DefaultConstructorCallSuper partially in parser. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 3 months 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 unified diff | Download patch
« no previous file with comments | « src/full-codegen/mips/full-codegen-mips.cc ('k') | src/full-codegen/ppc/full-codegen-ppc.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_MIPS64 5 #if V8_TARGET_ARCH_MIPS64
6 6
7 // Note on Mips implementation: 7 // Note on Mips implementation:
8 // 8 //
9 // The result_register() for mips is the 'v0' register, which is defined 9 // The result_register() for mips is the 'v0' register, which is defined
10 // by the ABI to contain function return values. However, the first 10 // by the ABI to contain function return values. However, the first
(...skipping 4120 matching lines...) Expand 10 before | Expand all | Expand 10 after
4131 __ bind(&done); 4131 __ bind(&done);
4132 4132
4133 context()->Plug(v0); 4133 context()->Plug(v0);
4134 } 4134 }
4135 4135
4136 4136
4137 void FullCodeGenerator::EmitDefaultConstructorCallSuper(CallRuntime* expr) { 4137 void FullCodeGenerator::EmitDefaultConstructorCallSuper(CallRuntime* expr) {
4138 ZoneList<Expression*>* args = expr->arguments(); 4138 ZoneList<Expression*>* args = expr->arguments();
4139 DCHECK(args->length() == 2); 4139 DCHECK(args->length() == 2);
4140 4140
4141 // new.target 4141 // Evaluate new.target and super constructor.
4142 VisitForStackValue(args->at(0)); 4142 VisitForStackValue(args->at(0));
4143
4144 // .this_function
4145 VisitForStackValue(args->at(1)); 4143 VisitForStackValue(args->at(1));
4146 __ CallRuntime(Runtime::kGetPrototype, 1);
4147 __ Push(result_register());
4148 4144
4149 // Load original constructor into a4. 4145 // Load original constructor into a4.
4150 __ ld(a4, MemOperand(sp, 1 * kPointerSize)); 4146 __ ld(a4, MemOperand(sp, 1 * kPointerSize));
4151 4147
4152 // Check if the calling frame is an arguments adaptor frame. 4148 // Check if the calling frame is an arguments adaptor frame.
4153 Label adaptor_frame, args_set_up, runtime; 4149 Label adaptor_frame, args_set_up, runtime;
4154 __ ld(a2, MemOperand(fp, StandardFrameConstants::kCallerFPOffset)); 4150 __ ld(a2, MemOperand(fp, StandardFrameConstants::kCallerFPOffset));
4155 __ ld(a3, MemOperand(a2, StandardFrameConstants::kContextOffset)); 4151 __ ld(a3, MemOperand(a2, StandardFrameConstants::kContextOffset));
4156 __ Branch(&adaptor_frame, eq, a3, 4152 __ Branch(&adaptor_frame, eq, a3,
4157 Operand(Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR))); 4153 Operand(Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR)));
(...skipping 1187 matching lines...) Expand 10 before | Expand all | Expand 10 after
5345 reinterpret_cast<uint64_t>( 5341 reinterpret_cast<uint64_t>(
5346 isolate->builtins()->OsrAfterStackCheck()->entry())); 5342 isolate->builtins()->OsrAfterStackCheck()->entry()));
5347 return OSR_AFTER_STACK_CHECK; 5343 return OSR_AFTER_STACK_CHECK;
5348 } 5344 }
5349 5345
5350 5346
5351 } // namespace internal 5347 } // namespace internal
5352 } // namespace v8 5348 } // namespace v8
5353 5349
5354 #endif // V8_TARGET_ARCH_MIPS64 5350 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/full-codegen/mips/full-codegen-mips.cc ('k') | src/full-codegen/ppc/full-codegen-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698