Skip to contentSkip to conversation

sparc64: fix done instruction pc

PATCH New Igor V. Kovalenko 1 participant 1 message Oct 4, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sparc64: fix done instruction pc

Fix done instruction to resume with pc=tnpc, npc=tnpc+4

---

 target-sparc/op_helper.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
target-sparc/op_helper.c +1 -1
index 8992d1c..a1ada8b 100644
@@ -3318,7 +3318,7 @@ void helper_done(void)
 {
     trap_state* tsptr = cpu_tsptr(env);
 
-    env->pc = tsptr->tpc;
+    env->pc = tsptr->tnpc;
     env->npc = tsptr->tnpc + 4;
     PUT_CCR(env, tsptr->tstate >> 32);
     env->asi = (tsptr->tstate >> 24) & 0xff;