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

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

Issue 1350113002: [runtime] Replace COMPARE/COMPARE_STRONG with proper Object::Compare. (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
« src/objects.cc ('K') | « src/runtime/runtime-strings.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/bootstrapper.h" 7 #include "src/bootstrapper.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/codegen.h" 9 #include "src/codegen.h"
10 #include "src/ic/handler-compiler.h" 10 #include "src/ic/handler-compiler.h"
(...skipping 1721 matching lines...) Expand 10 before | Expand all | Expand 10 after
1732 __ PopReturnAddressTo(rcx); 1732 __ PopReturnAddressTo(rcx);
1733 __ Push(rdx); 1733 __ Push(rdx);
1734 __ Push(rax); 1734 __ Push(rax);
1735 1735
1736 // Figure out which native to call and setup the arguments. 1736 // Figure out which native to call and setup the arguments.
1737 if (cc == equal) { 1737 if (cc == equal) {
1738 __ PushReturnAddressFrom(rcx); 1738 __ PushReturnAddressFrom(rcx);
1739 __ TailCallRuntime(strict() ? Runtime::kStrictEquals : Runtime::kEquals, 2, 1739 __ TailCallRuntime(strict() ? Runtime::kStrictEquals : Runtime::kEquals, 2,
1740 1); 1740 1);
1741 } else { 1741 } else {
1742 int context_index = is_strong(strength())
1743 ? Context::COMPARE_STRONG_BUILTIN_INDEX
1744 : Context::COMPARE_BUILTIN_INDEX;
1745 __ Push(Smi::FromInt(NegativeComparisonResult(cc))); 1742 __ Push(Smi::FromInt(NegativeComparisonResult(cc)));
1746 __ PushReturnAddressFrom(rcx); 1743 __ PushReturnAddressFrom(rcx);
1747 1744 __ TailCallRuntime(
1748 // Call the native; it returns -1 (less), 0 (equal), or 1 (greater) 1745 is_strong(strength()) ? Runtime::kCompare_Strong : Runtime::kCompare, 3,
1749 // tagged as a small integer. 1746 1);
1750 __ InvokeBuiltin(context_index, JUMP_FUNCTION);
1751 } 1747 }
1752 1748
1753 __ bind(&miss); 1749 __ bind(&miss);
1754 GenerateMiss(masm); 1750 GenerateMiss(masm);
1755 } 1751 }
1756 1752
1757 1753
1758 static void CallStubInRecordCallTarget(MacroAssembler* masm, CodeStub* stub, 1754 static void CallStubInRecordCallTarget(MacroAssembler* masm, CodeStub* stub,
1759 bool is_super) { 1755 bool is_super) {
1760 // rax : number of arguments to the construct function 1756 // rax : number of arguments to the construct function
(...skipping 3804 matching lines...) Expand 10 before | Expand all | Expand 10 after
5565 kStackSpace, nullptr, return_value_operand, NULL); 5561 kStackSpace, nullptr, return_value_operand, NULL);
5566 } 5562 }
5567 5563
5568 5564
5569 #undef __ 5565 #undef __
5570 5566
5571 } // namespace internal 5567 } // namespace internal
5572 } // namespace v8 5568 } // namespace v8
5573 5569
5574 #endif // V8_TARGET_ARCH_X64 5570 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/objects.cc ('K') | « src/runtime/runtime-strings.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698