public override PowerPcInstruction Decode(uint wInstr, PowerPcDisassembler dasm) { var key = (wInstr >> 0x4) & mask; if (decoders.TryGetValue(key, out Decoder decoder)) { return(decoder.Decode(wInstr, dasm)); } else { Debug.Print("Unknown PowerPC VMX instruction {0:X8} {1:X2}-{2:X3} ({2})", wInstr, wInstr >> 26, key); return(dasm.EmitUnknown(wInstr)); } }
public override PowerPcInstruction Decode(uint wInstr, PowerPcDisassembler dasm) { var subOp = (wInstr & 0xFFFF) >> 3; if (decoders.TryGetValue(subOp, out var decoder)) { return(decoder.Decode(wInstr, dasm)); } else { Debug.Print("Unknown PowerPC XX3 instruction {0:X8} {1:X2}-{2:X3} ({2})", wInstr, wInstr >> 26, subOp); return(dasm.EmitUnknown(wInstr)); } }
public override PowerPcInstruction Decode(uint wInstr, PowerPcDisassembler dasm) { var xOp = wInstr & 0x7FFu; if (vxDecoders.TryGetValue(xOp, out Decoder decoder)) { return(decoder.Decode(wInstr, dasm)); } else if (vaDecoders.TryGetValue(wInstr & 0x3Fu, out decoder)) { return(decoder.Decode(wInstr, dasm)); } else { Debug.Print("Unknown PowerPC VX instruction {0:X8} {1:X2}-{2:X3} ({2})", wInstr, wInstr >> 26, xOp); return(dasm.EmitUnknown(wInstr)); } }