OpCode32Sat.cs 731 B

123456789101112131415161718192021222324
  1. namespace ARMeilleure.Decoders
  2. {
  3. class OpCode32Sat : OpCode32
  4. {
  5. public int Rn { get; }
  6. public int Imm5 { get; }
  7. public int Rd { get; }
  8. public int SatImm { get; }
  9. public ShiftType ShiftType { get; }
  10. public new static OpCode Create(InstDescriptor inst, ulong address, int opCode) => new OpCode32Sat(inst, address, opCode);
  11. public OpCode32Sat(InstDescriptor inst, ulong address, int opCode) : base(inst, address, opCode)
  12. {
  13. Rn = (opCode >> 0) & 0xf;
  14. Imm5 = (opCode >> 7) & 0x1f;
  15. Rd = (opCode >> 12) & 0xf;
  16. SatImm = (opCode >> 16) & 0x1f;
  17. ShiftType = (ShiftType)((opCode >> 5) & 2);
  18. }
  19. }
  20. }