| 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 | 5 // modification, are permitted provided that the following conditions |
| 6 // are met: | 6 // are 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 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 bool is(Register reg) const { return code_ == reg.code_; } | 73 bool is(Register reg) const { return code_ == reg.code_; } |
| 74 int code() const { | 74 int code() const { |
| 75 ASSERT(is_valid()); | 75 ASSERT(is_valid()); |
| 76 return code_; | 76 return code_; |
| 77 } | 77 } |
| 78 int bit() const { | 78 int bit() const { |
| 79 ASSERT(is_valid()); | 79 ASSERT(is_valid()); |
| 80 return 1 << code_; | 80 return 1 << code_; |
| 81 } | 81 } |
| 82 | 82 |
| 83 // (unfortunately we can't make this private in a struct) | 83 // Unfortunately we can't make this private in a struct. |
| 84 int code_; | 84 int code_; |
| 85 }; | 85 }; |
| 86 | 86 |
| 87 | 87 |
| 88 extern Register no_reg; | 88 extern Register no_reg; |
| 89 extern Register r0; | 89 extern Register r0; |
| 90 extern Register r1; | 90 extern Register r1; |
| 91 extern Register r2; | 91 extern Register r2; |
| 92 extern Register r3; | 92 extern Register r3; |
| 93 extern Register r4; | 93 extern Register r4; |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 198 bool is(CRegister creg) const { return code_ == creg.code_; } | 198 bool is(CRegister creg) const { return code_ == creg.code_; } |
| 199 int code() const { | 199 int code() const { |
| 200 ASSERT(is_valid()); | 200 ASSERT(is_valid()); |
| 201 return code_; | 201 return code_; |
| 202 } | 202 } |
| 203 int bit() const { | 203 int bit() const { |
| 204 ASSERT(is_valid()); | 204 ASSERT(is_valid()); |
| 205 return 1 << code_; | 205 return 1 << code_; |
| 206 } | 206 } |
| 207 | 207 |
| 208 // (unfortunately we can't make this private in a struct) | 208 // Unfortunately we can't make this private in a struct. |
| 209 int code_; | 209 int code_; |
| 210 }; | 210 }; |
| 211 | 211 |
| 212 | 212 |
| 213 extern CRegister no_creg; | 213 extern CRegister no_creg; |
| 214 extern CRegister cr0; | 214 extern CRegister cr0; |
| 215 extern CRegister cr1; | 215 extern CRegister cr1; |
| 216 extern CRegister cr2; | 216 extern CRegister cr2; |
| 217 extern CRegister cr3; | 217 extern CRegister cr3; |
| 218 extern CRegister cr4; | 218 extern CRegister cr4; |
| (...skipping 24 matching lines...) Expand all Loading... |
| 243 p9 = 9, | 243 p9 = 9, |
| 244 p10 = 10, | 244 p10 = 10, |
| 245 p11 = 11, | 245 p11 = 11, |
| 246 p12 = 12, | 246 p12 = 12, |
| 247 p13 = 13, | 247 p13 = 13, |
| 248 p14 = 14, | 248 p14 = 14, |
| 249 p15 = 15 | 249 p15 = 15 |
| 250 }; | 250 }; |
| 251 | 251 |
| 252 | 252 |
| 253 // Condition field in instructions | 253 // Condition field in instructions. |
| 254 enum Condition { | 254 enum Condition { |
| 255 eq = 0 << 28, // Z set equal. | 255 eq = 0 << 28, // Z set equal. |
| 256 ne = 1 << 28, // Z clear not equal. | 256 ne = 1 << 28, // Z clear not equal. |
| 257 nz = 1 << 28, // Z clear not zero. | 257 nz = 1 << 28, // Z clear not zero. |
| 258 cs = 2 << 28, // C set carry set. | 258 cs = 2 << 28, // C set carry set. |
| 259 hs = 2 << 28, // C set unsigned higher or same. | 259 hs = 2 << 28, // C set unsigned higher or same. |
| 260 cc = 3 << 28, // C clear carry clear. | 260 cc = 3 << 28, // C clear carry clear. |
| 261 lo = 3 << 28, // C clear unsigned lower. | 261 lo = 3 << 28, // C clear unsigned lower. |
| 262 mi = 4 << 28, // N set negative. | 262 mi = 4 << 28, // N set negative. |
| 263 pl = 5 << 28, // N clear positive or zero. | 263 pl = 5 << 28, // N clear positive or zero. |
| (...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 621 // Convenience branch instructions using labels | 621 // Convenience branch instructions using labels |
| 622 void b(Label* L, Condition cond = al) { | 622 void b(Label* L, Condition cond = al) { |
| 623 b(branch_offset(L, cond == al), cond); | 623 b(branch_offset(L, cond == al), cond); |
| 624 } | 624 } |
| 625 void b(Condition cond, Label* L) { b(branch_offset(L, cond == al), cond); } | 625 void b(Condition cond, Label* L) { b(branch_offset(L, cond == al), cond); } |
| 626 void bl(Label* L, Condition cond = al) { bl(branch_offset(L, false), cond); } | 626 void bl(Label* L, Condition cond = al) { bl(branch_offset(L, false), cond); } |
| 627 void bl(Condition cond, Label* L) { bl(branch_offset(L, false), cond); } | 627 void bl(Condition cond, Label* L) { bl(branch_offset(L, false), cond); } |
| 628 void blx(Label* L) { blx(branch_offset(L, false)); } // v5 and above | 628 void blx(Label* L) { blx(branch_offset(L, false)); } // v5 and above |
| 629 | 629 |
| 630 // Data-processing instructions | 630 // Data-processing instructions |
| 631 void ubfx(Register dst, Register src1, const Operand& src2, |
| 632 const Operand& src3, Condition cond = al); |
| 633 |
| 631 void and_(Register dst, Register src1, const Operand& src2, | 634 void and_(Register dst, Register src1, const Operand& src2, |
| 632 SBit s = LeaveCC, Condition cond = al); | 635 SBit s = LeaveCC, Condition cond = al); |
| 633 | 636 |
| 634 void eor(Register dst, Register src1, const Operand& src2, | 637 void eor(Register dst, Register src1, const Operand& src2, |
| 635 SBit s = LeaveCC, Condition cond = al); | 638 SBit s = LeaveCC, Condition cond = al); |
| 636 | 639 |
| 637 void sub(Register dst, Register src1, const Operand& src2, | 640 void sub(Register dst, Register src1, const Operand& src2, |
| 638 SBit s = LeaveCC, Condition cond = al); | 641 SBit s = LeaveCC, Condition cond = al); |
| 639 void sub(Register dst, Register src1, Register src2, | 642 void sub(Register dst, Register src1, Register src2, |
| 640 SBit s = LeaveCC, Condition cond = al) { | 643 SBit s = LeaveCC, Condition cond = al) { |
| (...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1024 void RecordRelocInfo(RelocInfo::Mode rmode, intptr_t data = 0); | 1027 void RecordRelocInfo(RelocInfo::Mode rmode, intptr_t data = 0); |
| 1025 | 1028 |
| 1026 friend class RegExpMacroAssemblerARM; | 1029 friend class RegExpMacroAssemblerARM; |
| 1027 friend class RelocInfo; | 1030 friend class RelocInfo; |
| 1028 friend class CodePatcher; | 1031 friend class CodePatcher; |
| 1029 }; | 1032 }; |
| 1030 | 1033 |
| 1031 } } // namespace v8::internal | 1034 } } // namespace v8::internal |
| 1032 | 1035 |
| 1033 #endif // V8_ARM_ASSEMBLER_ARM_H_ | 1036 #endif // V8_ARM_ASSEMBLER_ARM_H_ |
| OLD | NEW |