From be07a3d39e44e32d4a918efc9febfd14aec01de3 Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Mon, 20 Jun 2011 16:50:51 +0000 Subject: [PATCH] * am33.igen (sub Rm,Rn,Rd): Fix computation of carry flag. --- sim/mn10300/ChangeLog | 4 ++++ sim/mn10300/am33.igen | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/sim/mn10300/ChangeLog b/sim/mn10300/ChangeLog index 2077186881a..1543b03cfb7 100644 --- a/sim/mn10300/ChangeLog +++ b/sim/mn10300/ChangeLog @@ -1,3 +1,7 @@ +2011-06-20 Nick Clifton + + * am33.igen (sub Rm,Rn,Rd): Fix computation of carry flag. + 2011-01-11 Andrew Burgess * interp.c (sim_store_register): Update return value to diff --git a/sim/mn10300/am33.igen b/sim/mn10300/am33.igen index f17283cfb4e..5bc96aca616 100644 --- a/sim/mn10300/am33.igen +++ b/sim/mn10300/am33.igen @@ -2573,7 +2573,7 @@ z = (difference == 0); n = (difference & 0x80000000); - c = (source1 > source1); + c = (source1 > source2); v = ((source1 & 0x80000000) == (source2 & 0x80000000) && (source1 & 0x80000000) != (difference & 0x80000000)); -- 2.30.2