From: Laurent Vivier Date: Sat, 16 Jan 2016 22:33:43 +0000 (+0100) Subject: target-m68k: suba/adda can manage word operand X-Git-Tag: TizenStudio_2.0_p2.3.2~9^2~14^2~5^2~100^2~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=415f4b62eb4629bd3702e6fb8aa51437a92983ff;p=sdk%2Femulator%2Fqemu.git target-m68k: suba/adda can manage word operand Signed-off-by: Laurent Vivier Reviewed-by: Richard Henderson --- diff --git a/target-m68k/translate.c b/target-m68k/translate.c index 3f7db83..b82ebf3 100644 --- a/target-m68k/translate.c +++ b/target-m68k/translate.c @@ -2011,7 +2011,7 @@ DISAS_INSN(suba) TCGv src; TCGv reg; - SRC_EA(env, src, OS_LONG, 0, NULL); + SRC_EA(env, src, (insn & 0x100) ? OS_LONG : OS_WORD, 1, NULL); reg = AREG(insn, 9); tcg_gen_sub_i32(reg, reg, src); } @@ -2203,7 +2203,7 @@ DISAS_INSN(adda) TCGv src; TCGv reg; - SRC_EA(env, src, OS_LONG, 0, NULL); + SRC_EA(env, src, (insn & 0x100) ? OS_LONG : OS_WORD, 1, NULL); reg = AREG(insn, 9); tcg_gen_add_i32(reg, reg, src); } @@ -3351,6 +3351,7 @@ void register_m68k_insns (CPUM68KState *env) INSN(subx_reg, 9100, f138, M68000); INSN(subx_mem, 9108, f138, M68000); INSN(suba, 91c0, f1c0, CF_ISA_A); + INSN(suba, 90c0, f0c0, M68000); BASE(undef_mac, a000, f000); INSN(mac, a000, f100, CF_EMAC);