summaryrefslogtreecommitdiff
path: root/target-sparc/op_helper.c
diff options
context:
space:
mode:
authorblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-07-17 19:17:19 +0000
committerblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2008-07-17 19:17:19 +0000
commite6bf7d70b5a459f96f0b2cbc677926eebe685c84 (patch)
tree588a5f287852858223eed1f5a88921cbcfd18188 /target-sparc/op_helper.c
parent2cade6a3f60cc203ee2b3fc44d06af3ec048e379 (diff)
downloadqemu-e6bf7d70b5a459f96f0b2cbc677926eebe685c84.tar.gz
Fix saving and loading of trap state
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4883 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-sparc/op_helper.c')
-rw-r--r--target-sparc/op_helper.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/target-sparc/op_helper.c b/target-sparc/op_helper.c
index b168f9cff0..3f508278ea 100644
--- a/target-sparc/op_helper.c
+++ b/target-sparc/op_helper.c
@@ -2680,26 +2680,26 @@ void helper_wrpstate(target_ulong new_state)
void helper_done(void)
{
- env->tl--;
- env->tsptr = &env->ts[env->tl];
env->pc = env->tsptr->tpc;
env->npc = env->tsptr->tnpc + 4;
PUT_CCR(env, env->tsptr->tstate >> 32);
env->asi = (env->tsptr->tstate >> 24) & 0xff;
change_pstate((env->tsptr->tstate >> 8) & 0xf3f);
PUT_CWP64(env, env->tsptr->tstate & 0xff);
+ env->tl--;
+ env->tsptr = &env->ts[env->tl];
}
void helper_retry(void)
{
- env->tl--;
- env->tsptr = &env->ts[env->tl];
env->pc = env->tsptr->tpc;
env->npc = env->tsptr->tnpc;
PUT_CCR(env, env->tsptr->tstate >> 32);
env->asi = (env->tsptr->tstate >> 24) & 0xff;
change_pstate((env->tsptr->tstate >> 8) & 0xf3f);
PUT_CWP64(env, env->tsptr->tstate & 0xff);
+ env->tl--;
+ env->tsptr = &env->ts[env->tl];
}
#endif