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

Side by Side Diff: src/ia32/code-stubs-ia32.cc

Issue 1306303003: [es6] Implement spec compliant ToPrimitive in the runtime. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Address Michis comments. 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
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_IA32 5 #if V8_TARGET_ARCH_IA32
6 6
7 #include "src/base/bits.h" 7 #include "src/base/bits.h"
8 #include "src/bootstrapper.h" 8 #include "src/bootstrapper.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 3253 matching lines...) Expand 10 before | Expand all | Expand 10 after
3264 Label not_oddball; 3264 Label not_oddball;
3265 __ CmpInstanceType(edi, ODDBALL_TYPE); 3265 __ CmpInstanceType(edi, ODDBALL_TYPE);
3266 __ j(not_equal, &not_oddball, Label::kNear); 3266 __ j(not_equal, &not_oddball, Label::kNear);
3267 __ mov(eax, FieldOperand(eax, Oddball::kToNumberOffset)); 3267 __ mov(eax, FieldOperand(eax, Oddball::kToNumberOffset));
3268 __ Ret(); 3268 __ Ret();
3269 __ bind(&not_oddball); 3269 __ bind(&not_oddball);
3270 3270
3271 __ pop(ecx); // Pop return address. 3271 __ pop(ecx); // Pop return address.
3272 __ push(eax); // Push argument. 3272 __ push(eax); // Push argument.
3273 __ push(ecx); // Push return address. 3273 __ push(ecx); // Push return address.
3274 __ InvokeBuiltin(Context::TO_NUMBER_BUILTIN_INDEX, JUMP_FUNCTION); 3274 __ TailCallRuntime(Runtime::kToNumber, 1, 1);
3275 } 3275 }
3276 3276
3277 3277
3278 void StringHelper::GenerateFlatOneByteStringEquals(MacroAssembler* masm, 3278 void StringHelper::GenerateFlatOneByteStringEquals(MacroAssembler* masm,
3279 Register left, 3279 Register left,
3280 Register right, 3280 Register right,
3281 Register scratch1, 3281 Register scratch1,
3282 Register scratch2) { 3282 Register scratch2) {
3283 Register length = scratch1; 3283 Register length = scratch1;
3284 3284
(...skipping 2251 matching lines...) Expand 10 before | Expand all | Expand 10 after
5536 Operand(ebp, 7 * kPointerSize), NULL); 5536 Operand(ebp, 7 * kPointerSize), NULL);
5537 } 5537 }
5538 5538
5539 5539
5540 #undef __ 5540 #undef __
5541 5541
5542 } // namespace internal 5542 } // namespace internal
5543 } // namespace v8 5543 } // namespace v8
5544 5544
5545 #endif // V8_TARGET_ARCH_IA32 5545 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/heap/heap.h ('k') | src/json-stringifier.h » ('j') | src/objects.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698