From 892c6b9d8fca691330232aaea9c0aaaff880feb1 Mon Sep 17 00:00:00 2001 From: Alexandre Oliva Date: Tue, 4 Jul 2000 06:35:36 +0000 Subject: * armemu.h (WRITEDESTB): New macro. * armemu.c (ARMul_Emulate26, bl): Use WriteR15Branch() to modify PC. Moved the existing logic... (WriteR15Branch): ... here. New function. (WriteR15, WriteSR15): Drop the two least significant bits. (LoadSMult): Use WriteR15Branch() to modify PC. (LoadMult): Use WRITEDESTB() instead of WRITEDEST(). --- sim/arm/armemu.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sim/arm/armemu.h') diff --git a/sim/arm/armemu.h b/sim/arm/armemu.h index da7fb2b429a..ad89294ffac 100644 --- a/sim/arm/armemu.h +++ b/sim/arm/armemu.h @@ -332,6 +332,11 @@ extern ARMword isize; ARMul_NegZero(state, d) ; \ } +#define WRITEDESTB(d) if (DESTReg == 15) \ + WriteR15Branch(state, d) ; \ + else \ + DEST = d + #define BYTETOBUS(data) ((data & 0xff) | \ ((data & 0xff) << 8) | \ ((data & 0xff) << 16) | \ -- cgit v1.2.1