OLD | NEW |
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/codegen.h" | 7 #include "src/codegen.h" |
8 #include "src/debug/debug.h" | 8 #include "src/debug/debug.h" |
9 #include "src/deoptimizer.h" | 9 #include "src/deoptimizer.h" |
10 #include "src/full-codegen/full-codegen.h" | 10 #include "src/full-codegen/full-codegen.h" |
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
711 | 711 |
712 // Flood function if we are stepping. | 712 // Flood function if we are stepping. |
713 Label skip_flooding; | 713 Label skip_flooding; |
714 ExternalReference step_in_enabled = | 714 ExternalReference step_in_enabled = |
715 ExternalReference::debug_step_in_enabled_address(masm->isolate()); | 715 ExternalReference::debug_step_in_enabled_address(masm->isolate()); |
716 __ li(t1, Operand(step_in_enabled)); | 716 __ li(t1, Operand(step_in_enabled)); |
717 __ lb(t1, MemOperand(t1)); | 717 __ lb(t1, MemOperand(t1)); |
718 __ Branch(&skip_flooding, eq, t1, Operand(zero_reg)); | 718 __ Branch(&skip_flooding, eq, t1, Operand(zero_reg)); |
719 { | 719 { |
720 FrameScope scope(masm, StackFrame::INTERNAL); | 720 FrameScope scope(masm, StackFrame::INTERNAL); |
721 __ Push(a1, a2, t0); | 721 __ Push(a1, a2, a4); |
722 __ CallRuntime(Runtime::kDebugPrepareStepInIfStepping); | 722 __ CallRuntime(Runtime::kDebugPrepareStepInIfStepping); |
723 __ Pop(a1, a2); | 723 __ Pop(a1, a2); |
724 __ ld(t0, FieldMemOperand(a1, JSGeneratorObject::kFunctionOffset)); | 724 __ ld(a4, FieldMemOperand(a1, JSGeneratorObject::kFunctionOffset)); |
725 } | 725 } |
726 __ bind(&skip_flooding); | 726 __ bind(&skip_flooding); |
727 | 727 |
728 // Push receiver. | 728 // Push receiver. |
729 __ ld(a5, FieldMemOperand(a1, JSGeneratorObject::kReceiverOffset)); | 729 __ ld(a5, FieldMemOperand(a1, JSGeneratorObject::kReceiverOffset)); |
730 __ Push(a5); | 730 __ Push(a5); |
731 | 731 |
732 // ----------- S t a t e ------------- | 732 // ----------- S t a t e ------------- |
733 // -- a1 : the JSGeneratorObject to resume | 733 // -- a1 : the JSGeneratorObject to resume |
734 // -- a2 : the resume mode (tagged) | 734 // -- a2 : the resume mode (tagged) |
(...skipping 25 matching lines...) Expand all Loading... |
760 FrameScope scope(masm, StackFrame::MANUAL); | 760 FrameScope scope(masm, StackFrame::MANUAL); |
761 __ Push(ra, fp); | 761 __ Push(ra, fp); |
762 __ Move(fp, sp); | 762 __ Move(fp, sp); |
763 __ Push(cp, a4); | 763 __ Push(cp, a4); |
764 | 764 |
765 // Restore the operand stack. | 765 // Restore the operand stack. |
766 __ ld(a0, FieldMemOperand(a1, JSGeneratorObject::kOperandStackOffset)); | 766 __ ld(a0, FieldMemOperand(a1, JSGeneratorObject::kOperandStackOffset)); |
767 __ ld(a3, FieldMemOperand(a0, FixedArray::kLengthOffset)); | 767 __ ld(a3, FieldMemOperand(a0, FixedArray::kLengthOffset)); |
768 __ SmiUntag(a3); | 768 __ SmiUntag(a3); |
769 __ Daddu(a0, a0, Operand(FixedArray::kHeaderSize - kHeapObjectTag)); | 769 __ Daddu(a0, a0, Operand(FixedArray::kHeaderSize - kHeapObjectTag)); |
770 __ Lsa(a3, a0, a3, kPointerSizeLog2); | 770 __ Dlsa(a3, a0, a3, kPointerSizeLog2); |
771 { | 771 { |
772 Label done_loop, loop; | 772 Label done_loop, loop; |
773 __ bind(&loop); | 773 __ bind(&loop); |
774 __ Branch(&done_loop, eq, a0, Operand(a3)); | 774 __ Branch(&done_loop, eq, a0, Operand(a3)); |
775 __ ld(a5, MemOperand(a0)); | 775 __ ld(a5, MemOperand(a0)); |
776 __ Push(a5); | 776 __ Push(a5); |
777 __ Branch(USE_DELAY_SLOT, &loop); | 777 __ Branch(USE_DELAY_SLOT, &loop); |
778 __ daddiu(a0, a0, kPointerSize); // In delay slot. | 778 __ daddiu(a0, a0, kPointerSize); // In delay slot. |
779 __ bind(&done_loop); | 779 __ bind(&done_loop); |
780 } | 780 } |
(...skipping 1920 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2701 } | 2701 } |
2702 } | 2702 } |
2703 | 2703 |
2704 | 2704 |
2705 #undef __ | 2705 #undef __ |
2706 | 2706 |
2707 } // namespace internal | 2707 } // namespace internal |
2708 } // namespace v8 | 2708 } // namespace v8 |
2709 | 2709 |
2710 #endif // V8_TARGET_ARCH_MIPS64 | 2710 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |