From: Dan Aloni <da-x@monatomic.org>
To: Benjamin LaHaise <bcrl@kvack.org>
Cc: "David S. Miller" <davem@davemloft.net>,
drepper@gmail.com, linux-kernel@vger.kernel.org
Subject: Re: Status of AIO
Date: Tue, 7 Mar 2006 04:04:11 +0200 [thread overview]
Message-ID: <20060307020411.GA21626@localdomain> (raw)
In-Reply-To: <20060307013915.GU20768@kvack.org>
On Mon, Mar 06, 2006 at 08:39:15PM -0500, Benjamin LaHaise wrote:
> On Mon, Mar 06, 2006 at 04:51:29PM -0800, David S. Miller wrote:
> > I think any such VM tricks need serious thought. It has serious
> > consequences as far as cost especially on SMP. Evgivny has some data
> > that shows this, and chapter 5 of Networking Algorithmics has a lot of
> > good analysis and paper references on this topic.
>
> VM tricks do suck, so you just have to use the tricks that nobody else
> is... My thinking is to do something like the following: have a structure
> to reference a set of pages. When it is first created, it takes a reference
> on the pages in question, and it is added to the vm_area_struct of the user
> so that the vm can poke it for freeing when memory pressure occurs. The
> sk_buff dataref also has to have a pointer to the pageref added. Now, the
> trick to making it useful is as follows:
>
> struct pageref {
> atomic_t free_count;
> int use_count; /* protected by socket lock */
> ...
> unsigned long user_address;
> unsigned long length;
> struct socket *sock; /* backref for VM */
> struct page *pages[];
> };
[...]
>
> It's probably easier to show this tx path with code that gets the details
> right.
This somehow resembles the scatter-gatter lists already used in some
subsystems such as the SCSI sg driver.
BTW you have to make these pages Copy-On-Write before this procedure
starts because you wouldn't want it to accidently fill the zero page,
i.e. the VM will have to supply a unique set of pages otherwise it
messes up.
--
Dan Aloni
da-x@monatomic.org, da-x@colinux.org, da-x@gmx.net, dan@xiv.co.il
next prev parent reply other threads:[~2006-03-07 2:02 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-06 6:24 Status of AIO Dan Aloni
2006-03-06 15:05 ` Phillip Susi
2006-03-06 21:18 ` Benjamin LaHaise
2006-03-06 22:53 ` Ulrich Drepper
2006-03-06 23:15 ` Phillip Susi
2006-03-08 7:09 ` Ulrich Drepper
2006-03-08 15:58 ` Phillip Susi
2006-03-06 23:33 ` Benjamin LaHaise
2006-03-07 0:24 ` David S. Miller
2006-03-07 0:42 ` Benjamin LaHaise
2006-03-07 0:51 ` David S. Miller
2006-03-07 1:39 ` Benjamin LaHaise
2006-03-07 2:04 ` Dan Aloni [this message]
2006-03-07 2:07 ` Benjamin LaHaise
2006-03-07 3:11 ` David S. Miller
2006-03-07 7:33 ` Dan Aloni
2006-03-07 3:06 ` David S. Miller
2006-03-07 16:35 ` Benjamin LaHaise
2006-03-07 1:34 ` Phillip Susi
2006-03-07 3:04 ` David S. Miller
2006-03-07 4:07 ` Phillip Susi
2006-03-07 6:02 ` David S. Miller
2006-03-07 16:06 ` Phillip Susi
2006-03-07 1:30 ` Dan Aloni
2006-03-07 1:37 ` Nicholas Miell
2006-03-07 1:37 ` Phillip Susi
2006-03-07 1:40 ` Benjamin LaHaise
2006-03-06 23:18 ` Phillip Susi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060307020411.GA21626@localdomain \
--to=da-x@monatomic.org \
--cc=bcrl@kvack.org \
--cc=davem@davemloft.net \
--cc=drepper@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.