From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sasha Levin Subject: Re: [PATCH] kvm tools: Support virtio indirect buffers Date: Mon, 28 Nov 2011 22:17:23 +0200 Message-ID: <1322511443.3629.7.camel@lappy> References: <1322502867-28812-1-git-send-email-levinsasha928@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, mingo@elte.hu, asias.hejun@gmail.com, gorcunov@gmail.com To: Pekka Enberg Return-path: Received: from mail-fx0-f46.google.com ([209.85.161.46]:33095 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753984Ab1K1URd (ORCPT ); Mon, 28 Nov 2011 15:17:33 -0500 Received: by faas1 with SMTP id s1so2999037faa.19 for ; Mon, 28 Nov 2011 12:17:32 -0800 (PST) In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On Mon, 2011-11-28 at 20:49 +0200, Pekka Enberg wrote: > On Mon, Nov 28, 2011 at 7:54 PM, Sasha Levin wrote: > > Indirect buffers are ring descriptors which point to more (even more) > > descriptors. > > > > This can be used to increase the effective ring capacity, which helps the > > guest to batch large requests - very useful for blk devices. > > > > This patch also enables indirect buffers for virtio-net and virtio-blk. > > > > The patch is based on the lguest's code which does the same. > > > > Signed-off-by: Sasha Levin > > In what exact way is it useful? Improved throughput? Will this have > negative impact on virtio block or virtio net latency? The total size of requests is limited by the size of the virtio ring. This makes it hard to squeeze large requests (like the ones you usually see with blk devices) into the ring. This patch simply makes each entry in the virtio ring point to another descriptor list, thus it allows to squeeze much more requests into a singe virtio ring. It shouldn't hurt latency. I tried getting benchmarks with it, but the results I get from fio are all over the place and I can't seem to get a steady result (bad sign for my poor spindle disk). -- Sasha.