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

Unified Diff: src/x64/code-stubs-x64.cc

Issue 1843933002: [stubs] Migrate ToLengthStub to TurboFan. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@MathCeil
Patch Set: REBASE Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/s390/code-stubs-s390.cc ('k') | src/x87/code-stubs-x87.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/x64/code-stubs-x64.cc
diff --git a/src/x64/code-stubs-x64.cc b/src/x64/code-stubs-x64.cc
index d4ccd91c872dfa39e871139f15b54473608bb827..1e12789ce602b6989a3f3354f4c21a0488a2d148 100644
--- a/src/x64/code-stubs-x64.cc
+++ b/src/x64/code-stubs-x64.cc
@@ -2599,25 +2599,6 @@ void StringToNumberStub::Generate(MacroAssembler* masm) {
__ TailCallRuntime(Runtime::kStringToNumber);
}
-void ToLengthStub::Generate(MacroAssembler* masm) {
- // The ToLength stub takes on argument in rax.
- Label not_smi, positive_smi;
- __ JumpIfNotSmi(rax, &not_smi, Label::kNear);
- STATIC_ASSERT(kSmiTag == 0);
- __ testp(rax, rax);
- __ j(greater_equal, &positive_smi, Label::kNear);
- __ xorl(rax, rax);
- __ bind(&positive_smi);
- __ Ret();
- __ bind(&not_smi);
-
- __ PopReturnAddressTo(rcx); // Pop return address.
- __ Push(rax); // Push argument.
- __ PushReturnAddressFrom(rcx); // Push return address.
- __ TailCallRuntime(Runtime::kToLength);
-}
-
-
void ToStringStub::Generate(MacroAssembler* masm) {
// The ToString stub takes one argument in rax.
Label is_number;
« no previous file with comments | « src/s390/code-stubs-s390.cc ('k') | src/x87/code-stubs-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698