OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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_ARM64_H_ | 5 #ifndef VM_CONSTANTS_ARM64_H_ |
6 #define VM_CONSTANTS_ARM64_H_ | 6 #define VM_CONSTANTS_ARM64_H_ |
7 | 7 |
8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
9 | 9 |
10 namespace dart { | 10 namespace dart { |
(...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
806 static const int32_t kBreakPointInstruction = // brk(0xdeb0). | 806 static const int32_t kBreakPointInstruction = // brk(0xdeb0). |
807 BRK | (kBreakPointCode << kImm16Shift); | 807 BRK | (kBreakPointCode << kImm16Shift); |
808 | 808 |
809 // Breakpoint instruction used by the simulator. | 809 // Breakpoint instruction used by the simulator. |
810 // Should be distinct from kBreakPointInstruction and from a typical user | 810 // Should be distinct from kBreakPointInstruction and from a typical user |
811 // breakpoint inserted in generated code for debugging, e.g. brk(0). | 811 // breakpoint inserted in generated code for debugging, e.g. brk(0). |
812 static const int32_t kSimulatorBreakpointInstruction = | 812 static const int32_t kSimulatorBreakpointInstruction = |
813 HLT | (kSimulatorBreakCode << kImm16Shift); | 813 HLT | (kSimulatorBreakCode << kImm16Shift); |
814 | 814 |
815 // Runtime call redirection instruction used by the simulator. | 815 // Runtime call redirection instruction used by the simulator. |
816 static const int32_t kRedirectInstruction = | 816 static const int32_t kSimulatorRedirectInstruction = |
817 HLT | (kSimulatorRedirectCode << kImm16Shift); | 817 HLT | (kSimulatorRedirectCode << kImm16Shift); |
818 | 818 |
819 // Read one particular bit out of the instruction bits. | 819 // Read one particular bit out of the instruction bits. |
820 inline int Bit(int nr) const { | 820 inline int Bit(int nr) const { |
821 return (InstructionBits() >> nr) & 1; | 821 return (InstructionBits() >> nr) & 1; |
822 } | 822 } |
823 | 823 |
824 // Read a bit field out of the instruction bits. | 824 // Read a bit field out of the instruction bits. |
825 inline int Bits(int shift, int count) const { | 825 inline int Bits(int shift, int count) const { |
826 return (InstructionBits() >> shift) & ((1 << count) - 1); | 826 return (InstructionBits() >> shift) & ((1 << count) - 1); |
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1058 static Instr* At(uword pc) { return reinterpret_cast<Instr*>(pc); } | 1058 static Instr* At(uword pc) { return reinterpret_cast<Instr*>(pc); } |
1059 | 1059 |
1060 private: | 1060 private: |
1061 DISALLOW_ALLOCATION(); | 1061 DISALLOW_ALLOCATION(); |
1062 DISALLOW_IMPLICIT_CONSTRUCTORS(Instr); | 1062 DISALLOW_IMPLICIT_CONSTRUCTORS(Instr); |
1063 }; | 1063 }; |
1064 | 1064 |
1065 } // namespace dart | 1065 } // namespace dart |
1066 | 1066 |
1067 #endif // VM_CONSTANTS_ARM64_H_ | 1067 #endif // VM_CONSTANTS_ARM64_H_ |
OLD | NEW |