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

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

Issue 2051113002: [stubs] ToNumberStub --> ToNumber builtin. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix full-code on non-x64 platforms Created 4 years, 6 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
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_MIPS 5 #if V8_TARGET_ARCH_MIPS
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 3321 matching lines...) Expand 10 before | Expand all | Expand 10 after
3332 Register scratch1 = a1; 3332 Register scratch1 = a1;
3333 __ li(scratch1, Operand(Smi::FromInt(count_value))); 3333 __ li(scratch1, Operand(Smi::FromInt(count_value)));
3334 __ AddBranchNoOvf(v0, v0, Operand(scratch1), &done); 3334 __ AddBranchNoOvf(v0, v0, Operand(scratch1), &done);
3335 // Call stub. Undo operation first. 3335 // Call stub. Undo operation first.
3336 __ Move(v0, a0); 3336 __ Move(v0, a0);
3337 __ jmp(&stub_call); 3337 __ jmp(&stub_call);
3338 __ bind(&slow); 3338 __ bind(&slow);
3339 } 3339 }
3340 3340
3341 // Convert old value into a number. 3341 // Convert old value into a number.
3342 ToNumberStub convert_stub(isolate()); 3342 __ Call(isolate()->builtins()->ToNumber(), RelocInfo::CODE_TARGET);
3343 __ CallStub(&convert_stub);
3344 PrepareForBailoutForId(expr->ToNumberId(), BailoutState::TOS_REGISTER); 3343 PrepareForBailoutForId(expr->ToNumberId(), BailoutState::TOS_REGISTER);
3345 3344
3346 // Save result for postfix expressions. 3345 // Save result for postfix expressions.
3347 if (expr->is_postfix()) { 3346 if (expr->is_postfix()) {
3348 if (!context()->IsEffect()) { 3347 if (!context()->IsEffect()) {
3349 // Save the result on the stack. If we have a named or keyed property 3348 // Save the result on the stack. If we have a named or keyed property
3350 // we store the result under the receiver that is currently on top 3349 // we store the result under the receiver that is currently on top
3351 // of the stack. 3350 // of the stack.
3352 switch (assign_type) { 3351 switch (assign_type) {
3353 case VARIABLE: 3352 case VARIABLE:
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
3828 reinterpret_cast<uint32_t>( 3827 reinterpret_cast<uint32_t>(
3829 isolate->builtins()->OnStackReplacement()->entry())); 3828 isolate->builtins()->OnStackReplacement()->entry()));
3830 return ON_STACK_REPLACEMENT; 3829 return ON_STACK_REPLACEMENT;
3831 } 3830 }
3832 3831
3833 3832
3834 } // namespace internal 3833 } // namespace internal
3835 } // namespace v8 3834 } // namespace v8
3836 3835
3837 #endif // V8_TARGET_ARCH_MIPS 3836 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/full-codegen/ia32/full-codegen-ia32.cc ('k') | src/full-codegen/mips64/full-codegen-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698