From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:35378) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbWvt-00064M-T4 for qemu-devel@nongnu.org; Thu, 22 Nov 2012 08:35:16 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TbWvk-0007X3-Hy for qemu-devel@nongnu.org; Thu, 22 Nov 2012 08:35:09 -0500 Received: from goliath.siemens.de ([192.35.17.28]:32141) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbWvk-0007U6-6A for qemu-devel@nongnu.org; Thu, 22 Nov 2012 08:35:00 -0500 Message-ID: <50AE2A01.4040306@siemens.com> Date: Thu, 22 Nov 2012 14:34:57 +0100 From: Jan Kiszka MIME-Version: 1.0 References: <1351697456-16107-1-git-send-email-pbonzini@redhat.com> <1351697456-16107-40-git-send-email-pbonzini@redhat.com> <50ACD536.2050205@siemens.com> <50ACD65E.6030300@redhat.com> <50ACD6B4.1050706@siemens.com> <50ACD835.4000206@redhat.com> <50ACD945.1040308@siemens.com> In-Reply-To: <50ACD945.1040308@siemens.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v2 39/39] raw-win32: implement native asynchronous I/O List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: "aliguori@us.ibm.com" , "qemu-devel@nongnu.org" , "stefanha@redhat.com" On 2012-11-21 14:38, Jan Kiszka wrote: > On 2012-11-21 14:33, Paolo Bonzini wrote: >> Il 21/11/2012 14:27, Jan Kiszka ha scritto: >>>>>>> Are there any patches flying around that are supposed to resolve = this? >>>>> >>>>> No. Is this with aio=3Dnative or aio=3Dthreads? >>> aio=3D - whatever that is on win32. >> >> That's aio=3Dthreads, just like POSIX. I'm curious (but not too >> optimistic) whether aio=3Dnative fixes it. >=20 > Just tried, and it actually makes no difference. >=20 >> >> Anyhow, do you have a reproducer that I can download? >=20 > Unfortunately, not at this point. Have to check, maybe I can trip the > image to the bare Linux guest. Maybe this helps: =3D>0 0xf77c242e __kernel_vsyscall+0xe() in [vdso].so (0x0519df88) 1 0xf761f10b __libc_read+0x4a() in libpthread.so.0 (0x0519df88) 2 0x7bc78c98 in ntdll (+0x68c97) (0x0519df88) 3 0x7bc7b0a3 in ntdll (+0x6b0a2) (0x0519e1b8) 4 0x7bc7b195 NtWaitForMultipleObjects+0x54() in ntdll (0x0519e1e8) 5 0x7b86de9f WaitForMultipleObjectsEx+0xee() in kernel32 (0x0519e338) 6 0x7b86df1a WaitForMultipleObjects+0x39() in kernel32 (0x0519e368) 7 0x0040301b aio_poll+0x16a(ctx=3D0x157610, blocking=3D) [/data/qemu/aio-win32.c:178] in qemu-system-arm (0x00000001) 8 0x004feec3 qemu_aio_wait+0x22() [/data/qemu/main-loop.c:442] in qemu-= system-arm (0x0105bdec) 9 0x00417166 bdrv_rw_co+0xa5(bs=3D0x159648, sector_num=3D, buf=3D"=C2=B9=C2=B8=C3=BF=C2=A6 = ", nb_sectors=3D0x4, is_write=3Dtrue) [/data/qemu/block.c:1997] = in qemu-system-arm (0x0105bdec) 10 0x00495544 in qemu-system-arm (+0x95543) (0x0105bdec) 11 0x0049592a pflash_write+0x3b9(pfl=3D0xd6f16e0, offset=3D, value=3D0x98f7fb1d, width=3D0x4, be=3D0) [/data/qemu/hw/pflash_cfi0= 1.c:405] in qemu-system-arm (0x0105bdec) 12 0x00618a7e io_mem_write+0xed(mr=3D0xd6f2a48, addr=3D0x105bdec, val=3D= 0x98f7fb1d, size=3D0x4) [/data/qemu/memory.c:911] in qemu-system-arm (0x0= 0000004) 13 0x0064088c helper_stl_mmu+0x2fb(env=3D0x15e268, addr=3D0xca05bdec, v= al=3D0x98f7fb1d, mmu_idx=3D0) [/data/qemu/softmmu_template.h:231] in qemu= -system-arm (0x3700001e) 14 0x02136637 (0x0015e268) It's the VCPU thread stuck in aio_poll, holding the BQL, blocking the iothread this way as well. Is there some race that prevents we receive the proper IO completion signal? Any states I should check? Jan --=20 Siemens AG, Corporate Technology, CT RTC ITP SDP-DE Corporate Competence Center Embedded Linux