Ejemplo n.º 1
0
 internal static bool InmZext(uint uInstr, YmpDisassembler dasm)
 {
     if (!dasm.rdr.TryReadBeUInt32(out uint nm))
     {
         return(false);
     }
     dasm.ops.Add(ImmediateOperand.Word64(nm));
     return(true);
 }
Ejemplo n.º 2
0
        internal static bool Jijkm(uint uInstr, YmpDisassembler dasm)
        {
            if (!dasm.rdr.TryReadBeUInt16(out ushort n))
            {
                return(false);
            }
            var uAddr = ((uInstr & 0x1FF) << 16) | n;

            dasm.ops.Add(AddressOperand.Ptr32(uAddr));
            return(true);
        }
Ejemplo n.º 3
0
        internal static bool Jnm(uint uInstr, YmpDisassembler dasm)
        {
            if (!dasm.rdr.TryReadBeUInt16(out ushort m))
            {
                return(false);
            }
            if (!dasm.rdr.TryReadBeUInt16(out ushort n))
            {
                return(false);
            }
            uint nm = n;

            nm = nm << 16 | m;
            dasm.ops.Add(AddressOperand.Ptr32(nm));
            return(true);
        }
Ejemplo n.º 4
0
            public override CrayInstruction Decode(uint wInstr, YmpDisassembler dasm)
            {
                foreach (var m in mutators)
                {
                    if (!m(wInstr, dasm))
                    {
                        return(dasm.CreateInvalidInstruction());
                    }
                }
                var instr = new CrayInstruction
                {
                    InstructionClass = iclass,
                    Mnemonic         = mnemonic,
                    Operands         = dasm.ops.ToArray()
                };

                return(instr);
            }
Ejemplo n.º 5
0
 internal static bool Imm_1(uint word, YmpDisassembler dasm)
 {
     dasm.ops.Add(ImmediateOperand.Word64(-1L));
     return(true);
 }