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

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

Issue 1687173006: MIPS: Fix '[runtime] Optimize and unify rest parameters.' (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix nits. 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
« no previous file with comments | « src/mips/macro-assembler-mips.cc ('k') | src/mips64/macro-assembler-mips64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_MIPS64 5 #if V8_TARGET_ARCH_MIPS64
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 5240 matching lines...) Expand 10 before | Expand all | Expand 10 after
5251 // -- cp : context 5251 // -- cp : context
5252 // -- a0 : number of rest parameters 5252 // -- a0 : number of rest parameters
5253 // -- a2 : pointer to first rest parameters 5253 // -- a2 : pointer to first rest parameters
5254 // -- ra : return address 5254 // -- ra : return address
5255 // ----------------------------------- 5255 // -----------------------------------
5256 5256
5257 // Allocate space for the rest parameter array plus the backing store. 5257 // Allocate space for the rest parameter array plus the backing store.
5258 Label allocate, done_allocate; 5258 Label allocate, done_allocate;
5259 __ li(a1, Operand(JSArray::kSize + FixedArray::kHeaderSize)); 5259 __ li(a1, Operand(JSArray::kSize + FixedArray::kHeaderSize));
5260 __ Dlsa(a1, a1, a0, kPointerSizeLog2); 5260 __ Dlsa(a1, a1, a0, kPointerSizeLog2);
5261 __ Allocate(a1, v0, a3, at, &allocate, TAG_OBJECT); 5261 __ Allocate(a1, v0, a3, a4, &allocate, TAG_OBJECT);
5262 __ bind(&done_allocate); 5262 __ bind(&done_allocate);
5263 5263
5264 // Compute arguments.length in a4. 5264 // Compute arguments.length in a4.
5265 __ SmiTag(a4, a0); 5265 __ SmiTag(a4, a0);
5266 5266
5267 // Setup the elements array in v0. 5267 // Setup the elements array in v0.
5268 __ LoadRoot(at, Heap::kFixedArrayMapRootIndex); 5268 __ LoadRoot(at, Heap::kFixedArrayMapRootIndex);
5269 __ sd(at, FieldMemOperand(v0, FixedArray::kMapOffset)); 5269 __ sd(at, FieldMemOperand(v0, FixedArray::kMapOffset));
5270 __ sd(a4, FieldMemOperand(v0, FixedArray::kLengthOffset)); 5270 __ sd(a4, FieldMemOperand(v0, FixedArray::kLengthOffset));
5271 __ Daddu(a3, v0, Operand(FixedArray::kHeaderSize)); 5271 __ Daddu(a3, v0, Operand(FixedArray::kHeaderSize));
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after
5768 return_value_operand, NULL); 5768 return_value_operand, NULL);
5769 } 5769 }
5770 5770
5771 5771
5772 #undef __ 5772 #undef __
5773 5773
5774 } // namespace internal 5774 } // namespace internal
5775 } // namespace v8 5775 } // namespace v8
5776 5776
5777 #endif // V8_TARGET_ARCH_MIPS64 5777 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/mips/macro-assembler-mips.cc ('k') | src/mips64/macro-assembler-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698