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

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

Issue 1126783003: Handle the case when derived constructor is [[Call]]ed with 0 args. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 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/code-stubs-mips.cc ('k') | src/x64/code-stubs-x64.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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_MIPS64 7 #if V8_TARGET_ARCH_MIPS64
8 8
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 1943 matching lines...) Expand 10 before | Expand all | Expand 10 after
1954 Operand(Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR))); 1954 Operand(Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR)));
1955 1955
1956 // Get the length from the frame. 1956 // Get the length from the frame.
1957 __ ld(a1, MemOperand(sp, 0)); 1957 __ ld(a1, MemOperand(sp, 0));
1958 __ Branch(&try_allocate); 1958 __ Branch(&try_allocate);
1959 1959
1960 // Patch the arguments.length and the parameters pointer. 1960 // Patch the arguments.length and the parameters pointer.
1961 __ bind(&adaptor_frame); 1961 __ bind(&adaptor_frame);
1962 __ ld(a1, MemOperand(a2, ArgumentsAdaptorFrameConstants::kLengthOffset)); 1962 __ ld(a1, MemOperand(a2, ArgumentsAdaptorFrameConstants::kLengthOffset));
1963 if (has_new_target()) { 1963 if (has_new_target()) {
1964 Label skip_decrement;
1965 __ Branch(&skip_decrement, eq, a1, Operand(Smi::FromInt(0)));
1964 // Subtract 1 from smi-tagged arguments count. 1966 // Subtract 1 from smi-tagged arguments count.
1965 __ SmiUntag(a1); 1967 __ SmiUntag(a1);
1966 __ Daddu(a1, a1, Operand(-1)); 1968 __ Daddu(a1, a1, Operand(-1));
1967 __ SmiTag(a1); 1969 __ SmiTag(a1);
1970 __ bind(&skip_decrement);
1968 } 1971 }
1969 __ sd(a1, MemOperand(sp, 0)); 1972 __ sd(a1, MemOperand(sp, 0));
1970 __ SmiScale(at, a1, kPointerSizeLog2); 1973 __ SmiScale(at, a1, kPointerSizeLog2);
1971 1974
1972 __ Daddu(a3, a2, Operand(at)); 1975 __ Daddu(a3, a2, Operand(at));
1973 1976
1974 __ Daddu(a3, a3, Operand(StandardFrameConstants::kCallerSPOffset)); 1977 __ Daddu(a3, a3, Operand(StandardFrameConstants::kCallerSPOffset));
1975 __ sd(a3, MemOperand(sp, 1 * kPointerSize)); 1978 __ sd(a3, MemOperand(sp, 1 * kPointerSize));
1976 1979
1977 // Try the new space allocation. Start out with computing the size 1980 // Try the new space allocation. Start out with computing the size
(...skipping 3562 matching lines...) Expand 10 before | Expand all | Expand 10 after
5540 kStackUnwindSpace, kInvalidStackOffset, 5543 kStackUnwindSpace, kInvalidStackOffset,
5541 MemOperand(fp, 6 * kPointerSize), NULL); 5544 MemOperand(fp, 6 * kPointerSize), NULL);
5542 } 5545 }
5543 5546
5544 5547
5545 #undef __ 5548 #undef __
5546 5549
5547 } } // namespace v8::internal 5550 } } // namespace v8::internal
5548 5551
5549 #endif // V8_TARGET_ARCH_MIPS64 5552 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/mips/code-stubs-mips.cc ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698