OLD | NEW |
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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_ARM64 | 7 #if V8_TARGET_ARCH_ARM64 |
8 | 8 |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/debug.h" | 10 #include "src/debug.h" |
(...skipping 740 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
751 __ Push(x11, x10); | 751 __ Push(x11, x10); |
752 __ Bind(&entry); | 752 __ Bind(&entry); |
753 __ Cmp(x4, x2); | 753 __ Cmp(x4, x2); |
754 __ B(gt, &loop); | 754 __ B(gt, &loop); |
755 // Because we copied values 2 by 2 we may have copied one extra value. | 755 // Because we copied values 2 by 2 we may have copied one extra value. |
756 // Drop it if that is the case. | 756 // Drop it if that is the case. |
757 __ B(eq, &done_copying_arguments); | 757 __ B(eq, &done_copying_arguments); |
758 __ Drop(1); | 758 __ Drop(1); |
759 __ Bind(&done_copying_arguments); | 759 __ Bind(&done_copying_arguments); |
760 | 760 |
| 761 __ Add(x0, x0, Operand(1)); // new.target |
| 762 |
| 763 |
| 764 // Handle step in. |
| 765 Label skip_step_in; |
| 766 ExternalReference debug_step_in_fp = |
| 767 ExternalReference::debug_step_in_fp_address(masm->isolate()); |
| 768 __ Mov(x2, Operand(debug_step_in_fp)); |
| 769 __ Ldr(x2, MemOperand(x2)); |
| 770 __ Cbz(x2, &skip_step_in); |
| 771 |
| 772 __ Push(x0, x1, x1); |
| 773 __ CallRuntime(Runtime::kHandleStepInForDerivedConstructors, 1); |
| 774 __ Pop(x1, x0); |
| 775 |
| 776 __ bind(&skip_step_in); |
| 777 |
761 // Call the function. | 778 // Call the function. |
762 // x0: number of arguments | 779 // x0: number of arguments |
763 // x1: constructor function | 780 // x1: constructor function |
764 __ Add(x0, x0, Operand(1)); // new.target | |
765 ParameterCount actual(x0); | 781 ParameterCount actual(x0); |
766 __ InvokeFunction(x1, actual, CALL_FUNCTION, NullCallWrapper()); | 782 __ InvokeFunction(x1, actual, CALL_FUNCTION, NullCallWrapper()); |
767 | 783 |
768 | 784 |
769 // Restore the context from the frame. | 785 // Restore the context from the frame. |
770 // x0: result | 786 // x0: result |
771 // jssp[0]: number of arguments (smi-tagged) | 787 // jssp[0]: number of arguments (smi-tagged) |
772 __ Ldr(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); | 788 __ Ldr(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); |
773 | 789 |
774 // Load number of arguments (smi). | 790 // Load number of arguments (smi). |
(...skipping 878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1653 __ Unreachable(); | 1669 __ Unreachable(); |
1654 } | 1670 } |
1655 } | 1671 } |
1656 | 1672 |
1657 | 1673 |
1658 #undef __ | 1674 #undef __ |
1659 | 1675 |
1660 } } // namespace v8::internal | 1676 } } // namespace v8::internal |
1661 | 1677 |
1662 #endif // V8_TARGET_ARCH_ARM | 1678 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |