On Mon, 10 Dec 2018 at 14:30, KONRAD Frederic <frederic.kon...@adacore.com> wrote: > > Hi Peter, > > Thanks for that patch! > > I'm seeing the same kind of issue when I run 8 qemu in parallel but it doesn't > seem to be fixed by this patch. Is it supposed to fix the issue when we are > doing a reset_request through a MMIO device? > > It happens (rarely) with this kind of guest code: > > exit: > write to the register to reset the device > loop: > branch loop > > The code after the reset is executed.. can't we exit the loop directly with > cpu_loop_exit after cpu_exit?
cpu_loop_exit would abort the execution of the store instruction that writes to the reset register. I'm not sure that's a great idea. My thought was more that we should just make sure that insn is the last one in the TB, so effectively we execute that insn and then reset the system before executing any further insns. Thinking it over though I'm not sure that we do do anything that could avoid having more insns following in the same TB, unless you're using singlestep or icount... thanks -- PMM