mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 00:33:55 -06:00
target/sh4: introduce DELAY_SLOT_MASK
This will make easier the introduction of a new flag in the next patches. Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
This commit is contained in:
parent
73479c5c87
commit
9a562ae7ba
3 changed files with 12 additions and 12 deletions
|
@ -172,11 +172,11 @@ void superh_cpu_do_interrupt(CPUState *cs)
|
|||
env->sgr = env->gregs[15];
|
||||
env->sr |= (1u << SR_BL) | (1u << SR_MD) | (1u << SR_RB);
|
||||
|
||||
if (env->flags & (DELAY_SLOT | DELAY_SLOT_CONDITIONAL)) {
|
||||
if (env->flags & DELAY_SLOT_MASK) {
|
||||
/* 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);
|
||||
env->flags &= ~DELAY_SLOT_MASK;
|
||||
}
|
||||
|
||||
if (do_exp) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue