aboutsummaryrefslogtreecommitdiff
path: root/target/sh4/helper.c
diff options
context:
space:
mode:
authorAurelien Jarno <aurelien@aurel32.net>2017-05-01 23:20:43 +0200
committerAurelien Jarno <aurelien@aurel32.net>2017-05-13 11:17:29 +0200
commit47b9f4d5a4013938134ca678c338906e798a61d7 (patch)
treeeb14ff757bc9eb0bbd345ba21d29fa2d41a244e5 /target/sh4/helper.c
parent24b09d9d8ba589402f9c8e0d8d36bcf5c4a933da (diff)
target/sh4: move DELAY_SLOT_TRUE flag into a separate global
Instead of using one bit of the env flags to store the condition of the next delay slot, use a separate global. It simplifies reading and writing the flags variable and also removes some confusion between ctx->envflags and env->flags. Note that the global is first transfered to a temp in order to be able to discard the global before the brcond. Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Diffstat (limited to 'target/sh4/helper.c')
-rw-r--r--target/sh4/helper.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/sh4/helper.c b/target/sh4/helper.c
index 71bb49a670..8f8ce81401 100644
--- a/target/sh4/helper.c
+++ b/target/sh4/helper.c
@@ -168,7 +168,7 @@ void superh_cpu_do_interrupt(CPUState *cs)
/* Branch instruction should be executed again before delay slot. */
env->spc -= 2;
/* Clear flags for exception/interrupt routine. */
- env->flags &= ~(DELAY_SLOT | DELAY_SLOT_CONDITIONAL | DELAY_SLOT_TRUE);
+ env->flags &= ~(DELAY_SLOT | DELAY_SLOT_CONDITIONAL);
}
if (do_exp) {