aboutsummaryrefslogtreecommitdiff
path: root/ARMeilleure/Decoders/OpCodeT32AluUmull.cs
blob: a1b2e6120335c4387acd5e69561f3015417fea3e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
namespace ARMeilleure.Decoders
{
    class OpCodeT32AluUmull : OpCodeT32, IOpCode32AluUmull
    {
        public int RdLo { get; }
        public int RdHi { get; }
        public int Rn { get; }
        public int Rm { get; }

        public bool NHigh { get; }
        public bool MHigh { get; }

        public bool? SetFlags => false;

        public new static OpCode Create(InstDescriptor inst, ulong address, int opCode) => new OpCodeT32AluUmull(inst, address, opCode);

        public OpCodeT32AluUmull(InstDescriptor inst, ulong address, int opCode) : base(inst, address, opCode)
        {
            Rm = (opCode >> 0) & 0xf;
            RdHi = (opCode >> 8) & 0xf;
            RdLo = (opCode >> 12) & 0xf;
            Rn = (opCode >> 16) & 0xf;

            MHigh = ((opCode >> 4) & 0x1) == 1;
            NHigh = ((opCode >> 5) & 0x1) == 1;
        }
    }
}