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

Side by Side Diff: src/crankshaft/x64/lithium-codegen-x64.cc

Issue 1609893003: [es6] Tail calls support. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 11 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 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/crankshaft/x64/lithium-codegen-x64.h" 7 #include "src/crankshaft/x64/lithium-codegen-x64.h"
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 3742 matching lines...) Expand 10 before | Expand all | Expand 10 after
3753 DCHECK(slot_register.is(rdx)); 3753 DCHECK(slot_register.is(rdx));
3754 DCHECK(vector_register.is(rbx)); 3754 DCHECK(vector_register.is(rbx));
3755 3755
3756 AllowDeferredHandleDereference vector_structure_check; 3756 AllowDeferredHandleDereference vector_structure_check;
3757 Handle<TypeFeedbackVector> vector = instr->hydrogen()->feedback_vector(); 3757 Handle<TypeFeedbackVector> vector = instr->hydrogen()->feedback_vector();
3758 int index = vector->GetIndex(instr->hydrogen()->slot()); 3758 int index = vector->GetIndex(instr->hydrogen()->slot());
3759 3759
3760 __ Move(vector_register, vector); 3760 __ Move(vector_register, vector);
3761 __ Move(slot_register, Smi::FromInt(index)); 3761 __ Move(slot_register, Smi::FromInt(index));
3762 3762
3763 // TODO(ishell): propagate correct TailCallMode
3763 Handle<Code> ic = 3764 Handle<Code> ic =
3764 CodeFactory::CallICInOptimizedCode(isolate(), arity, mode).code(); 3765 CodeFactory::CallICInOptimizedCode(isolate(), arity, mode).code();
3765 CallCode(ic, RelocInfo::CODE_TARGET, instr); 3766 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3766 } else { 3767 } else {
3767 __ Set(rax, arity); 3768 __ Set(rax, arity);
3768 CallCode(isolate()->builtins()->Call(mode), RelocInfo::CODE_TARGET, instr); 3769 CallCode(isolate()->builtins()->Call(mode), RelocInfo::CODE_TARGET, instr);
3769 } 3770 }
3770 } 3771 }
3771 3772
3772 3773
(...skipping 1889 matching lines...) Expand 10 before | Expand all | Expand 10 after
5662 RecordSafepoint(Safepoint::kNoLazyDeopt); 5663 RecordSafepoint(Safepoint::kNoLazyDeopt);
5663 } 5664 }
5664 5665
5665 5666
5666 #undef __ 5667 #undef __
5667 5668
5668 } // namespace internal 5669 } // namespace internal
5669 } // namespace v8 5670 } // namespace v8
5670 5671
5671 #endif // V8_TARGET_ARCH_X64 5672 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/compiler/js-operator.cc ('k') | src/flag-definitions.h » ('j') | src/x64/builtins-x64.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698