On 2017-05-10 10:43, Richard Henderson wrote: > On 05/10/2017 10:13 AM, Éric Bischoff wrote: > > Le mercredi 10 mai 2017, 12:16:20 Aurelien Jarno a écrit : > > > > + /* In a parallel context, stop the world and single step. */ > > > > + if (parallel_cpus) { > > > > + potential_page_fault(s); > > > > + gen_helper_exit_atomic(cpu_env); > > > > + return EXIT_NORETURN; > > > > + } > > > > > > One small additional comment about this patch I haven't spotted at the > > > first review. The exit_atomic helper is properly restoring the CPU state > > > passing the return address to cpu_loop_exit_atomic, so I believe the > > > potential_page_fault call is not necessary. That said, it doesn't hurt > > > either. > > > > Merci pour la relecture Aurélien. > > > > Richard, what do we do? We remove the potential_page_fault(s); or not? > > I'm thinking of using gen_exception(EXCP_ATOMIC) instead. > The unwind associated with the regular helper_exit_atomic > has more overhead than potential_page_fault().
That was just a remark to optimize the code a bit. That said I think the current code can go like that, it is not wrong. -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurel...@aurel32.net http://www.aurel32.net