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

Side by Side Diff: src/full-codegen/x87/full-codegen-x87.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
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | src/ia32/builtins-ia32.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_X87 5 #if V8_TARGET_ARCH_X87
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/code-factory.h" 8 #include "src/code-factory.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 3204 matching lines...) Expand 10 before | Expand all | Expand 10 after
3215 if (expr->op() == Token::INC) { 3215 if (expr->op() == Token::INC) {
3216 __ sub(eax, Immediate(Smi::FromInt(1))); 3216 __ sub(eax, Immediate(Smi::FromInt(1)));
3217 } else { 3217 } else {
3218 __ add(eax, Immediate(Smi::FromInt(1))); 3218 __ add(eax, Immediate(Smi::FromInt(1)));
3219 } 3219 }
3220 __ jmp(&stub_call, Label::kNear); 3220 __ jmp(&stub_call, Label::kNear);
3221 __ bind(&slow); 3221 __ bind(&slow);
3222 } 3222 }
3223 3223
3224 // Convert old value into a number. 3224 // Convert old value into a number.
3225 ToNumberStub convert_stub(isolate()); 3225 __ Call(masm->isolate()->builtins()->ToNumber(), RelocInfo::CODE_TARGET);
3226 __ CallStub(&convert_stub);
3227 PrepareForBailoutForId(expr->ToNumberId(), BailoutState::TOS_REGISTER); 3226 PrepareForBailoutForId(expr->ToNumberId(), BailoutState::TOS_REGISTER);
3228 3227
3229 // Save result for postfix expressions. 3228 // Save result for postfix expressions.
3230 if (expr->is_postfix()) { 3229 if (expr->is_postfix()) {
3231 if (!context()->IsEffect()) { 3230 if (!context()->IsEffect()) {
3232 // Save the result on the stack. If we have a named or keyed property 3231 // Save the result on the stack. If we have a named or keyed property
3233 // we store the result under the receiver that is currently on top 3232 // we store the result under the receiver that is currently on top
3234 // of the stack. 3233 // of the stack.
3235 switch (assign_type) { 3234 switch (assign_type) {
3236 case VARIABLE: 3235 case VARIABLE:
(...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after
3710 isolate->builtins()->OnStackReplacement()->entry(), 3709 isolate->builtins()->OnStackReplacement()->entry(),
3711 Assembler::target_address_at(call_target_address, unoptimized_code)); 3710 Assembler::target_address_at(call_target_address, unoptimized_code));
3712 return ON_STACK_REPLACEMENT; 3711 return ON_STACK_REPLACEMENT;
3713 } 3712 }
3714 3713
3715 3714
3716 } // namespace internal 3715 } // namespace internal
3717 } // namespace v8 3716 } // namespace v8
3718 3717
3719 #endif // V8_TARGET_ARCH_X87 3718 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | src/ia32/builtins-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698