From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: Ming Lei <tom.leiming@gmail.com>
Cc: Christoph Hellwig <hch@infradead.org>,
Linux FS Devel <linux-fsdevel@vger.kernel.org>,
linux-block@vger.kernel.org, lsf-pc@lists.linuxfoundation.org
Subject: Re: [Lsf-pc] [LSF/MM ATTEND] block: multipage bvecs
Date: Sun, 28 Feb 2016 09:09:35 -0800 [thread overview]
Message-ID: <1456679375.2324.13.camel@HansenPartnership.com> (raw)
In-Reply-To: <CACVXFVMc=UsFa9eTsVjhh92vk-uTPDL7-oO_2PoWNX=LK1acRA@mail.gmail.com>
On Mon, 2016-02-29 at 00:59 +0800, Ming Lei wrote:
> On Mon, Feb 29, 2016 at 12:45 AM, James Bottomley
> <James.Bottomley@hansenpartnership.com> wrote:
> > On Sun, 2016-02-28 at 08:29 -0800, Christoph Hellwig wrote:
> > > On Sun, Feb 28, 2016 at 08:26:46AM -0800, James Bottomley wrote:
> > > > You mean in bio_add_page() the code which currently aggregates
> > > > chunks within a page could build a bio vec entry up to the max
> > > > segment size? I think that is reasonable, especially now the
> > > > bio
> > > > splitting code can actually split inside a bio vec entry.
> > >
> > > Yes. Kent has an old prototype that did this at:
> > >
> > > https://evilpiepirate.org/git/linux-bcache.git/log/?h=block_stuff
> > >
> > > I don't think any of that is reusable as-is, but the basic idea
> > > is
> > > sounds and very useful.
> >
> > The basic idea, yes, but the actual code in that tree would still
> > have
> > built up bv entries that are too big. We have to thread
> > bio_add_page()
> > with knowledge of the queue limits, which is somewhat hard since
> > they're deliberately queue agnostic. Perhaps some global minimum
> > queue
> > segment size would work?
>
> IMO, we can just build contiguous segment simply into one vector
> because bio_add_page() in hot path, then compute segments during
> bio splitting from submit_bio() path by applying all kinds of queue
> limit just like current way.
We can debate this, but I'm dubious about the effectiveness. the
reason we have biovecs and don't use one bio per page is efficiency.
On large memory machines, most large IO transfers tend to be
physically contiguous because the allocators make it so. The splitting
code splits into bios not biovecs, so we'll likely end up with one bio
per segment. Is that better than one page per large biovec? Not sure,
someone will have to do careful benchmarking.
I'm not saying lets not do this, just that it's not an obvious win.
James
next prev parent reply other threads:[~2016-02-28 17:09 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-26 16:33 [LSF/MM ATTEND] block: multipage bvecs Ming Lei
2016-02-28 11:17 ` Boaz Harrosh
2016-02-28 14:34 ` Ming Lei
2016-02-28 14:41 ` Ming Lei
2016-02-28 16:01 ` [Lsf-pc] " James Bottomley
2016-02-29 9:41 ` Boaz Harrosh
2016-02-28 16:08 ` Christoph Hellwig
2016-02-29 10:16 ` Boaz Harrosh
2016-02-29 15:46 ` James Bottomley
2016-02-28 16:07 ` Christoph Hellwig
2016-02-28 16:26 ` James Bottomley
2016-02-28 16:29 ` Christoph Hellwig
2016-02-28 16:45 ` James Bottomley
2016-02-28 16:59 ` Ming Lei
2016-02-28 17:09 ` James Bottomley [this message]
2016-02-28 18:49 ` Ming Lei
2016-03-03 8:58 ` Christoph Hellwig
2016-03-03 11:04 ` Ming Lei
2016-03-03 12:11 ` Christoph Hellwig
2016-03-03 23:49 ` Ming Lin
2016-03-07 8:44 ` Ming Lei
2016-03-21 15:55 ` Christoph Hellwig
2016-03-22 0:12 ` Ming Lei
2016-03-05 8:35 ` Ming Lei
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=1456679375.2324.13.camel@HansenPartnership.com \
--to=james.bottomley@hansenpartnership.com \
--cc=hch@infradead.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=lsf-pc@lists.linuxfoundation.org \
--cc=tom.leiming@gmail.com \
/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.