| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 620 | 620 |
| 621 // Push multiple registers on the stack. | 621 // Push multiple registers on the stack. |
| 622 // Registers are saved in numerical order, with higher numbered registers | 622 // Registers are saved in numerical order, with higher numbered registers |
| 623 // saved in higher memory addresses. | 623 // saved in higher memory addresses. |
| 624 void MultiPush(RegList regs); | 624 void MultiPush(RegList regs); |
| 625 void MultiPushReversed(RegList regs); | 625 void MultiPushReversed(RegList regs); |
| 626 | 626 |
| 627 void MultiPushFPU(RegList regs); | 627 void MultiPushFPU(RegList regs); |
| 628 void MultiPushReversedFPU(RegList regs); | 628 void MultiPushReversedFPU(RegList regs); |
| 629 | 629 |
| 630 // Lower case push() for compatibility with arch-independent code. | |
| 631 void push(Register src) { | 630 void push(Register src) { |
| 632 Addu(sp, sp, Operand(-kPointerSize)); | 631 Addu(sp, sp, Operand(-kPointerSize)); |
| 633 sw(src, MemOperand(sp, 0)); | 632 sw(src, MemOperand(sp, 0)); |
| 634 } | 633 } |
| 634 void Push(Register src) { push(src); } |
| 635 | 635 |
| 636 // Push a handle. | 636 // Push a handle. |
| 637 void Push(Handle<Object> handle); | 637 void Push(Handle<Object> handle); |
| 638 void Push(Smi* smi) { Push(Handle<Smi>(smi, isolate())); } | 638 void Push(Smi* smi) { Push(Handle<Smi>(smi, isolate())); } |
| 639 | 639 |
| 640 // Push two registers. Pushes leftmost register first (to highest address). | 640 // Push two registers. Pushes leftmost register first (to highest address). |
| 641 void Push(Register src1, Register src2) { | 641 void Push(Register src1, Register src2) { |
| 642 Subu(sp, sp, Operand(2 * kPointerSize)); | 642 Subu(sp, sp, Operand(2 * kPointerSize)); |
| 643 sw(src1, MemOperand(sp, 1 * kPointerSize)); | 643 sw(src1, MemOperand(sp, 1 * kPointerSize)); |
| 644 sw(src2, MemOperand(sp, 0 * kPointerSize)); | 644 sw(src2, MemOperand(sp, 0 * kPointerSize)); |
| (...skipping 24 matching lines...) Expand all Loading... |
| 669 } | 669 } |
| 670 | 670 |
| 671 // Pops multiple values from the stack and load them in the | 671 // Pops multiple values from the stack and load them in the |
| 672 // registers specified in regs. Pop order is the opposite as in MultiPush. | 672 // registers specified in regs. Pop order is the opposite as in MultiPush. |
| 673 void MultiPop(RegList regs); | 673 void MultiPop(RegList regs); |
| 674 void MultiPopReversed(RegList regs); | 674 void MultiPopReversed(RegList regs); |
| 675 | 675 |
| 676 void MultiPopFPU(RegList regs); | 676 void MultiPopFPU(RegList regs); |
| 677 void MultiPopReversedFPU(RegList regs); | 677 void MultiPopReversedFPU(RegList regs); |
| 678 | 678 |
| 679 // Lower case pop() for compatibility with arch-independent code. | |
| 680 void pop(Register dst) { | 679 void pop(Register dst) { |
| 681 lw(dst, MemOperand(sp, 0)); | 680 lw(dst, MemOperand(sp, 0)); |
| 682 Addu(sp, sp, Operand(kPointerSize)); | 681 Addu(sp, sp, Operand(kPointerSize)); |
| 683 } | 682 } |
| 683 void Pop(Register dst) { pop(dst); } |
| 684 | 684 |
| 685 // Pop two registers. Pops rightmost register first (from lower address). | 685 // Pop two registers. Pops rightmost register first (from lower address). |
| 686 void Pop(Register src1, Register src2) { | 686 void Pop(Register src1, Register src2) { |
| 687 ASSERT(!src1.is(src2)); | 687 ASSERT(!src1.is(src2)); |
| 688 lw(src2, MemOperand(sp, 0 * kPointerSize)); | 688 lw(src2, MemOperand(sp, 0 * kPointerSize)); |
| 689 lw(src1, MemOperand(sp, 1 * kPointerSize)); | 689 lw(src1, MemOperand(sp, 1 * kPointerSize)); |
| 690 Addu(sp, sp, 2 * kPointerSize); | 690 Addu(sp, sp, 2 * kPointerSize); |
| 691 } | 691 } |
| 692 | 692 |
| 693 // Pop three registers. Pops rightmost register first (from lower address). | 693 // Pop three registers. Pops rightmost register first (from lower address). |
| (...skipping 893 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1587 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) | 1587 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) |
| 1588 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 1588 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
| 1589 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 1589 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
| 1590 #else | 1590 #else |
| 1591 #define ACCESS_MASM(masm) masm-> | 1591 #define ACCESS_MASM(masm) masm-> |
| 1592 #endif | 1592 #endif |
| 1593 | 1593 |
| 1594 } } // namespace v8::internal | 1594 } } // namespace v8::internal |
| 1595 | 1595 |
| 1596 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ | 1596 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ |
| OLD | NEW |