[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] replay: wake up vCPU when replaying
From: |
Pavel Dovgalyuk |
Subject: |
Re: [Qemu-devel] [PATCH] replay: wake up vCPU when replaying |
Date: |
Tue, 11 Sep 2018 10:37:22 +0300 |
> From: Paolo Bonzini [mailto:address@hidden
> On 09/07/2018 13:24, Pavel Dovgalyuk wrote:
> > static void qemu_tcg_rr_wait_io_event(CPUState *cpu)
> > {
> > while (all_cpu_threads_idle()) {
> > stop_tcg_kick_timer();
> > qemu_cond_wait(cpu->halt_cond, &qemu_global_mutex);
> > }
> >
> > start_tcg_kick_timer();
> >
> > qemu_wait_io_event_common(cpu);
> > }
> >
> > all_cpu_threads_idle() returns true when there is no queued work.
> > But between this call and qemu_cond_wait() iothread may add queued work
> > and the vCPU thread will sleep infinitely.
>
> Maybe queue_work_on_cpu is called outside BQL?
I don't remember now.
However, rr series includes the better version of that patch.
Pavel Dovgalyuk