| OLD | NEW |
| 1 // Copyright (c) 1994-2006 Sun Microsystems Inc. | 1 // Copyright (c) 1994-2006 Sun Microsystems Inc. |
| 2 // All Rights Reserved. | 2 // All Rights Reserved. |
| 3 // | 3 // |
| 4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
| 5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
| 6 // met: | 6 // met: |
| 7 // | 7 // |
| 8 // - Redistributions of source code must retain the above copyright notice, | 8 // - Redistributions of source code must retain the above copyright notice, |
| 9 // this list of conditions and the following disclaimer. | 9 // this list of conditions and the following disclaimer. |
| 10 // | 10 // |
| (...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 474 DCHECK((o & 3) == 0); // Assert the offset is aligned. | 474 DCHECK((o & 3) == 0); // Assert the offset is aligned. |
| 475 return o >> 2; | 475 return o >> 2; |
| 476 } | 476 } |
| 477 int32_t shifted_branch_offset_compact(Label* L, | 477 int32_t shifted_branch_offset_compact(Label* L, |
| 478 bool jump_elimination_allowed) { | 478 bool jump_elimination_allowed) { |
| 479 int32_t o = branch_offset_compact(L, jump_elimination_allowed); | 479 int32_t o = branch_offset_compact(L, jump_elimination_allowed); |
| 480 DCHECK((o & 3) == 0); // Assert the offset is aligned. | 480 DCHECK((o & 3) == 0); // Assert the offset is aligned. |
| 481 return o >> 2; | 481 return o >> 2; |
| 482 } | 482 } |
| 483 uint64_t jump_address(Label* L); | 483 uint64_t jump_address(Label* L); |
| 484 uint64_t jump_offset(Label* L); |
| 484 | 485 |
| 485 // Puts a labels target address at the given position. | 486 // Puts a labels target address at the given position. |
| 486 // The high 8 bits are set to zero. | 487 // The high 8 bits are set to zero. |
| 487 void label_at_put(Label* L, int at_offset); | 488 void label_at_put(Label* L, int at_offset); |
| 488 | 489 |
| 489 // Read/Modify the code target address in the branch/call instruction at pc. | 490 // Read/Modify the code target address in the branch/call instruction at pc. |
| 490 static Address target_address_at(Address pc); | 491 static Address target_address_at(Address pc); |
| 491 static void set_target_address_at(Address pc, | 492 static void set_target_address_at(Address pc, |
| 492 Address target, | 493 Address target, |
| 493 ICacheFlushMode icache_flush_mode = | 494 ICacheFlushMode icache_flush_mode = |
| (...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 726 void bnvc(Register rs, Register rt, Label* L) { | 727 void bnvc(Register rs, Register rt, Label* L) { |
| 727 bnvc(rs, rt, branch_offset_compact(L, false)>>2); | 728 bnvc(rs, rt, branch_offset_compact(L, false)>>2); |
| 728 } | 729 } |
| 729 | 730 |
| 730 // Never use the int16_t b(l)cond version with a branch offset | 731 // Never use the int16_t b(l)cond version with a branch offset |
| 731 // instead of using the Label* version. | 732 // instead of using the Label* version. |
| 732 | 733 |
| 733 // Jump targets must be in the current 256 MB-aligned region. i.e. 28 bits. | 734 // Jump targets must be in the current 256 MB-aligned region. i.e. 28 bits. |
| 734 void j(int64_t target); | 735 void j(int64_t target); |
| 735 void jal(int64_t target); | 736 void jal(int64_t target); |
| 737 void j(Label* target); |
| 738 void jal(Label* target); |
| 736 void jalr(Register rs, Register rd = ra); | 739 void jalr(Register rs, Register rd = ra); |
| 737 void jr(Register target); | 740 void jr(Register target); |
| 738 void jic(Register rt, int16_t offset); | 741 void jic(Register rt, int16_t offset); |
| 739 void jialc(Register rt, int16_t offset); | 742 void jialc(Register rt, int16_t offset); |
| 740 | 743 |
| 741 | 744 |
| 742 // -------Data-processing-instructions--------- | 745 // -------Data-processing-instructions--------- |
| 743 | 746 |
| 744 // Arithmetic. | 747 // Arithmetic. |
| 745 void addu(Register rd, Register rs, Register rt); | 748 void addu(Register rd, Register rs, Register rt); |
| (...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1489 class EnsureSpace BASE_EMBEDDED { | 1492 class EnsureSpace BASE_EMBEDDED { |
| 1490 public: | 1493 public: |
| 1491 explicit EnsureSpace(Assembler* assembler) { | 1494 explicit EnsureSpace(Assembler* assembler) { |
| 1492 assembler->CheckBuffer(); | 1495 assembler->CheckBuffer(); |
| 1493 } | 1496 } |
| 1494 }; | 1497 }; |
| 1495 | 1498 |
| 1496 } } // namespace v8::internal | 1499 } } // namespace v8::internal |
| 1497 | 1500 |
| 1498 #endif // V8_ARM_ASSEMBLER_MIPS_H_ | 1501 #endif // V8_ARM_ASSEMBLER_MIPS_H_ |
| OLD | NEW |