On 2017-07-05 14:23, Richard Henderson wrote: > For uniprocessors, SH4 uses optimistic restartable atomic sequences. > Upon an interrupt, a real kernel would simply notice magic values in > the registers and reset the PC to the start of the sequence. > > For QEMU, we cannot do this in quite the same way. Instead, we notice > the normal start of such a sequence (mov #-x,r15), and start a new TB > that can be executed under cpu_exec_step_atomic. > > Reported-by: Bruno Haible <br...@clisp.org> > LP: https://bugs.launchpad.net/bugs/1701971 > Signed-off-by: Richard Henderson <r...@twiddle.net> > --- > target/sh4/cpu.h | 21 ++++++-- > target/sh4/helper.h | 1 + > target/sh4/op_helper.c | 6 +++ > target/sh4/translate.c | 137 > +++++++++++++++++++++++++++++++++++++++++++------ > 4 files changed, 147 insertions(+), 18 deletions(-)
I haven't reviewed this patch in details, but note that it breaks booting a system under qemu-system. -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurel...@aurel32.net http://www.aurel32.net