| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_CONSTANTS_ARM_H_ | 5 #ifndef VM_CONSTANTS_ARM_H_ |
| 6 #define VM_CONSTANTS_ARM_H_ | 6 #define VM_CONSTANTS_ARM_H_ |
| 7 | 7 |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 | 9 |
| 10 namespace dart { | 10 namespace dart { |
| (...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 547 ((Bits(4, 4) & 0xd) == 1)); | 547 ((Bits(4, 4) & 0xd) == 1)); |
| 548 } | 548 } |
| 549 | 549 |
| 550 // Test for VFP load and store instructions of type 6. | 550 // Test for VFP load and store instructions of type 6. |
| 551 inline bool IsVFPLoadStore() const { | 551 inline bool IsVFPLoadStore() const { |
| 552 ASSERT(ConditionField() != kSpecialCondition); | 552 ASSERT(ConditionField() != kSpecialCondition); |
| 553 ASSERT(TypeField() == 6); | 553 ASSERT(TypeField() == 6); |
| 554 return ((Bits(20, 5) & 0x12) == 0x10) && (Bits(9, 3) == 5); | 554 return ((Bits(20, 5) & 0x12) == 0x10) && (Bits(9, 3) == 5); |
| 555 } | 555 } |
| 556 | 556 |
| 557 // Only handle mrc of the id_isar0 register. | |
| 558 inline bool IsMrcIdIsar0() const { | |
| 559 ASSERT(ConditionField() != kSpecialCondition); | |
| 560 ASSERT(TypeField() == 7); | |
| 561 return (Bits(21, 3) == 0) && (Bits(16, 4) == 0) && | |
| 562 (Bits(8, 4) == 0xf) && (Bits(5, 3) == 0) && | |
| 563 (Bits(0, 4) == 2); | |
| 564 } | |
| 565 | |
| 566 // Test for VFP multiple load and store instructions of type 6. | 557 // Test for VFP multiple load and store instructions of type 6. |
| 567 inline bool IsVFPMultipleLoadStore() const { | 558 inline bool IsVFPMultipleLoadStore() const { |
| 568 ASSERT(ConditionField() != kSpecialCondition); | 559 ASSERT(ConditionField() != kSpecialCondition); |
| 569 ASSERT(TypeField() == 6); | 560 ASSERT(TypeField() == 6); |
| 570 int32_t puw = (PUField() << 1) | Bit(21); // don't care about D bit | 561 int32_t puw = (PUField() << 1) | Bit(21); // don't care about D bit |
| 571 return (Bits(9, 3) == 5) && ((puw == 2) || (puw == 3) || (puw == 5)); | 562 return (Bits(9, 3) == 5) && ((puw == 2) || (puw == 3) || (puw == 5)); |
| 572 } | 563 } |
| 573 | 564 |
| 574 // Special accessors that test for existence of a value. | 565 // Special accessors that test for existence of a value. |
| 575 inline bool HasS() const { return SField() == 1; } | 566 inline bool HasS() const { return SField() == 1; } |
| (...skipping 11 matching lines...) Expand all Loading... |
| 587 static Instr* At(uword pc) { return reinterpret_cast<Instr*>(pc); } | 578 static Instr* At(uword pc) { return reinterpret_cast<Instr*>(pc); } |
| 588 | 579 |
| 589 private: | 580 private: |
| 590 DISALLOW_ALLOCATION(); | 581 DISALLOW_ALLOCATION(); |
| 591 DISALLOW_IMPLICIT_CONSTRUCTORS(Instr); | 582 DISALLOW_IMPLICIT_CONSTRUCTORS(Instr); |
| 592 }; | 583 }; |
| 593 | 584 |
| 594 } // namespace dart | 585 } // namespace dart |
| 595 | 586 |
| 596 #endif // VM_CONSTANTS_ARM_H_ | 587 #endif // VM_CONSTANTS_ARM_H_ |
| OLD | NEW |