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

Side by Side Diff: src/full-codegen/mips/full-codegen-mips.cc

Issue 1609893003: [es6] Tail calls support. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebasing Created 4 years, 10 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_MIPS 5 #if V8_TARGET_ARCH_MIPS
6 6
7 // Note on Mips implementation: 7 // Note on Mips implementation:
8 // 8 //
9 // The result_register() for mips is the 'v0' register, which is defined 9 // The result_register() for mips is the 'v0' register, which is defined
10 // by the ABI to contain function return values. However, the first 10 // by the ABI to contain function return values. However, the first
(...skipping 2842 matching lines...) Expand 10 before | Expand all | Expand 10 after
2853 // Load the arguments. 2853 // Load the arguments.
2854 ZoneList<Expression*>* args = expr->arguments(); 2854 ZoneList<Expression*>* args = expr->arguments();
2855 int arg_count = args->length(); 2855 int arg_count = args->length();
2856 for (int i = 0; i < arg_count; i++) { 2856 for (int i = 0; i < arg_count; i++) {
2857 VisitForStackValue(args->at(i)); 2857 VisitForStackValue(args->at(i));
2858 } 2858 }
2859 2859
2860 PrepareForBailoutForId(expr->CallId(), NO_REGISTERS); 2860 PrepareForBailoutForId(expr->CallId(), NO_REGISTERS);
2861 // Record source position of the IC call. 2861 // Record source position of the IC call.
2862 SetCallPosition(expr); 2862 SetCallPosition(expr);
2863 Handle<Code> ic = CodeFactory::CallIC(isolate(), arg_count, mode).code(); 2863 Handle<Code> ic =
2864 CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
2865 .code();
2864 __ li(a3, Operand(SmiFromSlot(expr->CallFeedbackICSlot()))); 2866 __ li(a3, Operand(SmiFromSlot(expr->CallFeedbackICSlot())));
2865 __ lw(a1, MemOperand(sp, (arg_count + 1) * kPointerSize)); 2867 __ lw(a1, MemOperand(sp, (arg_count + 1) * kPointerSize));
2866 // Don't assign a type feedback id to the IC, since type feedback is provided 2868 // Don't assign a type feedback id to the IC, since type feedback is provided
2867 // by the vector above. 2869 // by the vector above.
2868 CallIC(ic); 2870 CallIC(ic);
2869 2871
2870 RecordJSReturnSite(expr); 2872 RecordJSReturnSite(expr);
2871 // Restore context register. 2873 // Restore context register.
2872 __ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); 2874 __ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
2873 context()->DropAndPlug(1, v0); 2875 context()->DropAndPlug(1, v0);
(...skipping 1929 matching lines...) Expand 10 before | Expand all | Expand 10 after
4803 reinterpret_cast<uint32_t>( 4805 reinterpret_cast<uint32_t>(
4804 isolate->builtins()->OsrAfterStackCheck()->entry())); 4806 isolate->builtins()->OsrAfterStackCheck()->entry()));
4805 return OSR_AFTER_STACK_CHECK; 4807 return OSR_AFTER_STACK_CHECK;
4806 } 4808 }
4807 4809
4808 4810
4809 } // namespace internal 4811 } // namespace internal
4810 } // namespace v8 4812 } // namespace v8
4811 4813
4812 #endif // V8_TARGET_ARCH_MIPS 4814 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/full-codegen/ia32/full-codegen-ia32.cc ('k') | src/full-codegen/mips64/full-codegen-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698