Received: from eggs.gnu.org ([2001:4830:134:3::10]:33532) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YVLiL-0002a1-7C for qemu-devel@nongnu.org; Tue, 10 Mar 2015 11:05:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YVLiI-0005q8-Du for qemu-devel@nongnu.org; Tue, 10 Mar 2015 11:04:57 -0400 Received: from mx2.parallels.com ([199.115.105.18]:51173) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YVLiI-0005q1-7d for qemu-devel@nongnu.org; Tue, 10 Mar 2015 11:04:54 -0400 Date: Tue, 10 Mar 2015 18:04:28 +0300 From: Roman Kagan Message-ID: <20150310150427.GI6024@rkaganb.sw.ru> References: <1425977481-13317-1-git-send-email-den@openvz.org> <1425977481-13317-25-git-send-email-den@openvz.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <1425977481-13317-25-git-send-email-den@openvz.org> Subject: Re: [Qemu-devel] [PATCH 24/27] block/parallels: delay writing to BAT till bdrv_co_flush_to_os List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Denis V. Lunev" Cc: Kevin Wolf , qemu-devel@nongnu.org, Stefan Hajnoczi On Tue, Mar 10, 2015 at 11:51:18AM +0300, Denis V. Lunev wrote: > The idea is that we do not need to immediately sync BAT to the image as > from the guest point of view there is a possibility that IO is lost > even in the physical controller until flush command was finished. > bdrv_co_flush_to_os is exactly the right place for this purpose. > > Technically the patch uses loaded BAT data as a cache and performs > actual on-disk metadata updates in parallels_co_flush_to_os callback. > > This patch speed ups > qemu-img create -f parallels -o cluster_size=64k ./1.hds 64G > qemu-io -f parallels -c "write -P 0x11 0 1024k" 1.hds > writing from 50-60 Mb/sec to 80-90 Mb/sec on rotational media and > from 160 Mb/sec to 190 Mb/sec on SSD disk. > > Signed-off-by: Denis V. Lunev > CC: Roman Kagan > CC: Kevin Wolf > CC: Stefan Hajnoczi > --- > block/parallels.c | 50 ++++++++++++++++++++++++++++++++++++++++++++------ > 1 file changed, 44 insertions(+), 6 deletions(-) Reviewed-by: Roman Kagan Roman.