qemu-e2k/target/rx
Tomoaki Kawada 724eaecec6 target/rx: update PC correctly in wait instruction
`cpu_pc` at this point does not necessary point to the current
instruction (i.e., the wait instruction being translated), so it's
incorrect to calculate the new value of `cpu_pc` based on this. It must
be updated with `ctx->base.pc_next`, which contains the correct address
of the next instruction.

This change fixes the wait instruction skipping the subsequent branch
when used in an idle loop like this:

    0:  wait
        bra.b 0b
        brk   // should be unreachable

Signed-off-by: Tomoaki Kawada <i@yvt.jp>
Reviewed-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20220417060224.2131788-1-i@yvt.jp>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
2022-04-21 10:09:12 -07:00
..
cpu-param.h target/rx: CPU definitions 2020-03-19 17:58:05 +01:00
cpu-qom.h target: Introduce and use OBJECT_DECLARE_CPU_TYPE() macro 2022-03-06 22:23:09 +01:00
cpu.c Remove qemu-common.h include from most units 2022-04-06 14:31:55 +02:00
cpu.h target/rx: Store PSW.U in tb->flags 2022-04-21 10:04:33 -07:00
disas.c meson: target 2020-08-21 06:30:35 -04:00
gdbstub.c Remove qemu-common.h include from most units 2022-04-06 14:31:55 +02:00
helper.c target/rx: Restrict cpu_exec_interrupt() handler to sysemu 2021-09-14 12:00:21 -07:00
helper.h target/rx: Drop checks for singlestep_enabled 2021-10-15 16:39:14 -07:00
insns.decode target/rx: Fix Lesser GPL version number 2020-10-27 00:22:56 +01:00
Kconfig meson: Introduce target-specific Kconfig 2021-07-09 18:21:34 +02:00
meson.build meson: target 2020-08-21 06:30:35 -04:00
op_helper.c target/rx: set PSW.I when executing wait instruction 2022-04-21 10:08:05 -07:00
translate.c target/rx: update PC correctly in wait instruction 2022-04-21 10:09:12 -07:00