Beispiel #1
0
            public override ArcInstruction Decode(uint hInstr, ArcDisassembler dasm)
            {
                if (!dasm.rdr.TryReadUInt16(out ushort loword))
                {
                    return(dasm.CreateInvalidInstruction());
                }
                var uInstr = ((uint)hInstr) << 16;

                uInstr |= loword;
                return(decoder.Decode(uInstr, dasm));
            }
Beispiel #2
0
            public override ArcInstruction Decode(uint wInstr, ArcDisassembler dasm)
            {
                foreach (var m in mutators)
                {
                    if (!m(wInstr, dasm))
                    {
                        return(dasm.CreateInvalidInstruction());
                    }
                }
                var instr = new ArcInstruction
                {
                    InstructionClass = iclass,
                    Mnemonic         = mnemonic,
                    Operands         = dasm.ops.ToArray()
                };

                return(instr);
            }