Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2022-08-02 Thread Peter Maydell
On Tue, 20 Aug 2019 at 08:12, Paolo Bonzini wrote: > > There is a race between TCG and accesses to the dirty log: > > vCPU thread reader thread > --- --- > TLB check -> slow path > notdirty_mem_write >

Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2019-09-12 Thread Paolo Bonzini
Il gio 12 set 2019, 19:43 Richard Henderson ha scritto: > >>> Fortunately, in order to fix it, no change is required to the > >>> vCPU thread. However, the reader thread must delay the read after > >>> the vCPU thread has finished the write. This can be approximated > >>> conservatively by

Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2019-09-12 Thread Richard Henderson
u-devel@nongnu.org; Qemu-devel >> Subject: Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and >> accesses to dirty >> bitmap >> >> This patch breaks the execution recording. >> While vCPU tries to lock replay mutex in main while loop, >> vga

Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2019-09-12 Thread Paolo Bonzini
On 26/08/19 14:19, dovgaluk wrote: > This patch breaks the execution recording. > While vCPU tries to lock replay mutex in main while loop, > vga causes dirty memory sync and do_run_on_cpu call. > This call waits for vCPU to process the work queue. IIUC there is a deadlock because VGA (from the

Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2019-09-12 Thread Pavel Dovgalyuk
Ping. Pavel Dovgalyuk > -Original Message- > From: dovgaluk [mailto:dovga...@ispras.ru] > Sent: Monday, August 26, 2019 3:19 PM > To: Paolo Bonzini; pavel.dovga...@ispras.ru > Cc: qemu-devel@nongnu.org; Qemu-devel > Subject: Re: [Qemu-devel] [PULL 15/36] memory: fi

Re: [Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2019-08-26 Thread dovgaluk
This patch breaks the execution recording. While vCPU tries to lock replay mutex in main while loop, vga causes dirty memory sync and do_run_on_cpu call. This call waits for vCPU to process the work queue. Pavel Dovgalyuk Paolo Bonzini писал 2019-08-20 09:59: There is a race between TCG and

[Qemu-devel] [PULL 15/36] memory: fix race between TCG and accesses to dirty bitmap

2019-08-20 Thread Paolo Bonzini
There is a race between TCG and accesses to the dirty log: vCPU thread reader thread --- --- TLB check -> slow path notdirty_mem_write write to RAM set dirty flag