Cui, Dexuan
2007-May-28 11:15 UTC
[Xen-devel] [PATCH] Fix the very-slow-IDE-IO-speed issue of Qemu 0.90
c/s 15021 updated Qemu to 0.90. In the new Qemu''s ide.c, asynchronous IO (AIO) is used to replace the previous DMA thread; here when an AIO request is completed, dom0 sends a signal SIGUSR2 to Qemu (see block-raw.c: qemu_aio_init(),raw_aio_setup()), then the signal interrupts the select() in main_loop_wait() at once, next, qemu_aio_poll() is called to reap a completed AIO request. However, in certain Linux distributions (i.e., x86_64 RHEL 4u4), if Qemu is spawned by the python script image.py of Control Panel, the SIGUSR2 of Qemu is blocked by default due to some reasons (i.e. it seems Python 2.3.4 has this issue; 2.4.2 is ok); so in most cases the select() in main_loop_wait() can only time out in 10ms, then the qemu_aio_poll() is called - this results in a very slow disk IO speed... The attached patch ensures aio_sig_num is unblocked when the AIO is used in Qemu 0.90. Signed-off-by: Dexuan Cui <dexuan.cui@intel.com> _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Ian Pratt
2007-May-29 05:25 UTC
RE: [Xen-devel] [PATCH] Fix the very-slow-IDE-IO-speed issue of Qemu0.90
> c/s 15021 updated Qemu to 0.90. In the new Qemu''s ide.c, asynchronousIO> (AIO) is used to replace the previous DMA thread; here when an AIO > request is completed, dom0 sends a signal SIGUSR2 to Qemu (see > block-raw.c: qemu_aio_init(),raw_aio_setup()), then the signal > interrupts the select() in main_loop_wait() at once, next, > qemu_aio_poll() is called to reap a completed AIO request. > > However, in certain Linux distributions (i.e., x86_64 RHEL 4u4), if > Qemu is spawned by the python script image.py of Control Panel, theSIGUSR2> of Qemu is blocked by default due to some reasonsGood work figuring this out! It perfectly explains why most folk weren''t seeing the problem. Have you got any comparative performance numbers comparing IDE performance before and after the 0.90 upgrade (with your fix)? Are we back to roughly where we were? Thanks, Ian _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Cui, Dexuan
2007-May-29 05:49 UTC
RE: [Xen-devel] [PATCH] Fix the very-slow-IDE-IO-speed issue of Qemu0.90
I did some simple disk IO tests. Using c/s 15021 plus my fix, I''m sure the disk performance does back to roughly where we were. -- Dexuan -----Original Message----- From: Ian Pratt [mailto:Ian.Pratt@cl.cam.ac.uk] Sent: 2007年5月29日 13:26 To: Cui, Dexuan; xen-devel Cc: ian.pratt@cl.cam.ac.uk Subject: RE: [Xen-devel] [PATCH] Fix the very-slow-IDE-IO-speed issue of Qemu0.90> Have you got any comparative performance numbers comparing IDE > performance before and after the 0.90 upgrade (with your fix)? Are we > back to roughly where we were?Ian _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel