Merge pull request #1921 from huth/fixes

m68k: Add support for the FNOP instruction
This commit is contained in:
Wu ChenXu 2022-10-07 13:57:15 +08:00 committed by GitHub
commit 215822fde7

View File

@ -1784,6 +1784,13 @@ static void d68020_cpbcc_16(m68k_info *info)
cs_m68k* ext;
LIMIT_CPU_TYPES(info, M68020_PLUS);
// FNOP is a special case of FBF
if (info->ir == 0xf280 && peek_imm_16(info) == 0) {
MCInst_setOpcode(info->inst, M68K_INS_FNOP);
info->pc += 2;
return;
}
// these are all in row with the extension so just doing a add here is fine
info->inst->Opcode += (info->ir & 0x2f);
@ -1803,8 +1810,6 @@ static void d68020_cpbcc_32(m68k_info *info)
LIMIT_CPU_TYPES(info, M68020_PLUS);
LIMIT_CPU_TYPES(info, M68020_PLUS);
// these are all in row with the extension so just doing a add here is fine
info->inst->Opcode += (info->ir & 0x2f);