aboutsummaryrefslogtreecommitdiff
path: root/target/m68k
diff options
context:
space:
mode:
authorLaurent Vivier <laurent@vivier.eu>2016-11-03 14:50:03 -0600
committerLaurent Vivier <laurent@vivier.eu>2016-12-27 18:16:42 +0100
commit817af1c72d227fd5759ef882bef61acee40679b1 (patch)
treec84076add12bbe0effb7855121d36071e0bf9053 /target/m68k
parentf84aab269ddab8509b77408b886e9071bf5c48fb (diff)
downloadqemu-817af1c72d227fd5759ef882bef61acee40679b1.zip
qemu-817af1c72d227fd5759ef882bef61acee40679b1.tar.gz
qemu-817af1c72d227fd5759ef882bef61acee40679b1.tar.bz2
target-m68k: add cmpm
Signed-off-by: Laurent Vivier <laurent@vivier.eu> Reviewed-by: Richard Henderson <rth@twiddle.net> Message-Id: <1477604609-2206-2-git-send-email-laurent@vivier.eu> Signed-off-by: Richard Henderson <rth@twiddle.net> Message-Id: <1478206203-4606-4-git-send-email-rth@twiddle.net>
Diffstat (limited to 'target/m68k')
-rw-r--r--target/m68k/translate.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/target/m68k/translate.c b/target/m68k/translate.c
index aaa221e..97edb7b 100644
--- a/target/m68k/translate.c
+++ b/target/m68k/translate.c
@@ -2224,6 +2224,21 @@ DISAS_INSN(cmpa)
gen_update_cc_cmp(s, reg, src, OS_LONG);
}
+DISAS_INSN(cmpm)
+{
+ int opsize = insn_opsize(insn);
+ TCGv src, dst;
+
+ /* Post-increment load (mode 3) from Ay. */
+ src = gen_ea_mode(env, s, 3, REG(insn, 0), opsize,
+ NULL_QREG, NULL, EA_LOADS);
+ /* Post-increment load (mode 3) from Ax. */
+ dst = gen_ea_mode(env, s, 3, REG(insn, 9), opsize,
+ NULL_QREG, NULL, EA_LOADS);
+
+ gen_update_cc_cmp(s, dst, src, opsize);
+}
+
DISAS_INSN(eor)
{
TCGv src;
@@ -3465,6 +3480,7 @@ void register_m68k_insns (CPUM68KState *env)
INSN(cmpa, b1c0, f1c0, CF_ISA_A);
INSN(cmp, b000, f100, M68000);
INSN(eor, b100, f100, M68000);
+ INSN(cmpm, b108, f138, M68000);
INSN(cmpa, b0c0, f0c0, M68000);
INSN(eor, b180, f1c0, CF_ISA_A);
BASE(and, c000, f000);