| 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_MIPS_H_ | 5 #ifndef VM_CONSTANTS_MIPS_H_ |
| 6 #define VM_CONSTANTS_MIPS_H_ | 6 #define VM_CONSTANTS_MIPS_H_ |
| 7 | 7 |
| 8 namespace dart { | 8 namespace dart { |
| 9 | 9 |
| 10 enum Register { | 10 enum Register { |
| (...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 | 279 |
| 280 | 280 |
| 281 class Instr { | 281 class Instr { |
| 282 public: | 282 public: |
| 283 enum { | 283 enum { |
| 284 kInstrSize = 4, | 284 kInstrSize = 4, |
| 285 }; | 285 }; |
| 286 | 286 |
| 287 static const int32_t kBreakPointInstruction = | 287 static const int32_t kBreakPointInstruction = |
| 288 (SPECIAL << kOpcodeShift) | (BREAK << kFunctionShift); | 288 (SPECIAL << kOpcodeShift) | (BREAK << kFunctionShift); |
| 289 static const int32_t kNopInstruction = 0; |
| 289 | 290 |
| 290 // Get the raw instruction bits. | 291 // Get the raw instruction bits. |
| 291 inline int32_t InstructionBits() const { | 292 inline int32_t InstructionBits() const { |
| 292 return reinterpret_cast<int32_t>(this); | 293 return reinterpret_cast<int32_t>(this); |
| 293 } | 294 } |
| 294 | 295 |
| 295 // Read one particular bit out of the instruction bits. | 296 // Read one particular bit out of the instruction bits. |
| 296 inline int32_t Bit(int nr) const { | 297 inline int32_t Bit(int nr) const { |
| 297 return (InstructionBits() >> nr) & 1; | 298 return (InstructionBits() >> nr) & 1; |
| 298 } | 299 } |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 345 } | 346 } |
| 346 | 347 |
| 347 private: | 348 private: |
| 348 DISALLOW_ALLOCATION(); | 349 DISALLOW_ALLOCATION(); |
| 349 DISALLOW_IMPLICIT_CONSTRUCTORS(Instr); | 350 DISALLOW_IMPLICIT_CONSTRUCTORS(Instr); |
| 350 }; | 351 }; |
| 351 | 352 |
| 352 } // namespace dart | 353 } // namespace dart |
| 353 | 354 |
| 354 #endif // VM_CONSTANTS_MIPS_H_ | 355 #endif // VM_CONSTANTS_MIPS_H_ |
| OLD | NEW |