qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] buffer alignment for block backends


From: Samuel Thibault
Subject: Re: [Qemu-devel] buffer alignment for block backends
Date: Thu, 9 Apr 2009 18:13:02 +0200
User-agent: Mutt/1.5.12-2006-07-14

Gerd Hoffmann, le Thu 09 Apr 2009 17:50:19 +0200, a écrit :
> On 04/09/09 17:21, Samuel Thibault wrote:
> >Gerd Hoffmann, le Thu 09 Apr 2009 15:54:34 +0200, a écrit :
> >>On 04/09/09 15:30, Stefano Stabellini wrote:
> >>>The userspace\kernelspace distinction does not make much sense in
> >>>minios, but yes it provides an interface to communicate with blkback in
> >>>dom0. This interface is used by block-vbd in qemu instead of
> >>>block-raw-posix when run in minios.
> >>Sit back, look again.  Do you really need it being page-aligned?
> >
> >Page aligned is an optimization which comes for free when you can
> >already choose the alignment.
> 
> Ok, so you don't have to.
> 
> Does it have an effect positive actually?  i.e. do you have requests 
> which would fit into one page but actually span two due to the misalignment?

I/O with small files often fit in just one page. If they're never
aligned the amount of grants to transfer is doubled.

> At least when watching the linux kernel access pattern I see larger 
> requests being page aligned anyway.
> Probably page cache reads and writes.

Yes, that's what I meant in another mail. Usually, I/O will already be
aligned.  That's not a reason for not trying to optimize other cases.

Samuel




reply via email to

[Prev in Thread] Current Thread [Next in Thread]