lkml.org 
[lkml]   [2011]   [Dec]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] virtio-ring: Use threshold for switching to indirect descriptors
On Sun, Dec 04, 2011 at 05:16:59PM +0200, Avi Kivity wrote:
> On 12/04/2011 05:11 PM, Michael S. Tsirkin wrote:
> > > There's also the used ring, but that's a
> > > mistake if you have out of order completion. We should have used copying.
> >
> > Seems unrelated... unless you want used to be written into
> > descriptor ring itself?
>
> The avail/used rings are in addition to the regular ring, no?

Yes. A couple of extra pages, if we reduce alignment we could pack this
in a single extra page.

> If you
> copy descriptors, then it goes away.

The avail ring could go away. used could if we make descriptors
writeable. IIUC it was made RO in the hope that will make it
easier for xen to adopt. Still relevant?

> > But, I don't really know why does virtio ring insist on
> > making the 3 buffers (avail/used/descriptor)
> > physically contigious. Rusty?
>
> Let's drop them instead.
>
> >
> > > 16kB worth of descriptors is 1024 entries. With 4kB buffers, that's 4MB
> > > worth of data, or 4 ms at 10GbE line speed. With 1500 byte buffers it's
> > > just 1.5 ms. In any case I think it's sufficient.
> >
> > Right. So I think that without indirect, we waste about 3 entries
> > per packet for virtio header and transport etc headers.
>
> That does suck. Are there issues in increasing the ring size? Or
> making it discontiguous?

discontiguous ring is what indirect is, basically.

> Can you take a peek at how Xen manages its rings? They have the same
> problems we do.
>
> --
> error compiling committee.c: too many arguments to function


\
 
 \ /
  Last update: 2011-12-04 17:01    [W:2.106 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site