From 0ccccfe4939cceec05ac6f954ffd491607e3c1bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benedikt=20B=C3=B6hm?= Date: Tue, 19 May 2009 12:12:45 +0200 Subject: fix CMP instruction --- src/emu/cpu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/emu/cpu.c b/src/emu/cpu.c index b0664cd..5256cb6 100644 --- a/src/emu/cpu.c +++ b/src/emu/cpu.c @@ -195,8 +195,8 @@ void execute(uint32_t IR) memcpy(&MEM[GPR[a] + c], &tmp32, sizeof(uint32_t)); break; case OPC_CMP: - Z = (GPR[b] == (uint32_t) c); - N = (GPR[b] < (uint32_t) c); + Z = (GPR[a] == GPR[b]); + N = (GPR[a] < GPR[b]); break; case OPC_BEQ: if (Z) -- cgit v1.2.3