From 3463c3fbbbaf4466adce4b8c712924e96c624d0b Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Tue, 23 May 2000 23:52:46 +0000 Subject: [PATCH] Add special case handling when GDB set CPSR register --- sim/arm/ChangeLog | 5 +++++ sim/arm/wrapper.c | 8 +++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/sim/arm/ChangeLog b/sim/arm/ChangeLog index bb55ddd8f10..9649c3999b8 100644 --- a/sim/arm/ChangeLog +++ b/sim/arm/ChangeLog @@ -1,3 +1,8 @@ +2000-05-23 Nick Clifton + + * wrapper.c (sim_store_register): Special handling for CPSR + register. + 2000-03-11 Philip Blundell * armemu.c (LoadSMult, LoadMult): Correct handling of aborts. diff --git a/sim/arm/wrapper.c b/sim/arm/wrapper.c index 8417f40938e..003dec6d594 100644 --- a/sim/arm/wrapper.c +++ b/sim/arm/wrapper.c @@ -320,7 +320,13 @@ sim_store_register (sd, rn, memory, length) int length ATTRIBUTE_UNUSED; { init (); - ARMul_SetReg (state, state->Mode, rn, frommem (state, memory)); + if (rn == 25) + { + state->Cpsr = frommem (state, memory); + ARMul_CPSRAltered (state); + } + else + ARMul_SetReg (state, state->Mode, rn, frommem (state, memory)); return -1; } -- 2.30.2