Re: [PATCH 2/4] xfs: Introduce writeback context for writepages

Dave Chinner
2015-11-10T23:26:31Z

[ finally getting back to this :/ ]

On Tue, Sep 01, 2015 at 12:41:03AM -0700, Christoph Hellwig wrote:
> On Tue, Sep 01, 2015 at 08:17:43AM +1000, Dave Chinner wrote:
> > The patch changes the bio allocation patterns - it allocates them on
> > the fly and holds them, so we could potentially exhaust the bio
> > mempool with this submission technique.
>
> I've spend time to look over the patch again, and still don't see
> a change.

Ah, it's in the next patch that I haven't posted that "goes straight
to bios". Ignore it for now...

> > The ioend allocation pattern
> > is different, too, because we only used to have 1 per buffer on a
> > writepage call and the last one was used for the write clustering.
>
> .. that we now build up way bigger ioend chains.
>
> So back to Brians concern: we can now have fairly large piles of
> ioends built up while potentially getting scheduled out, and this
> does look like a potential real issue to me. I wonder if we should
> (ab-)use the blk_plug_cb infrastructure so that we can flush the
> pending ioends out on a context switch?

Possibly, but I'm thinking that we should just end up building bios
directly and submitting them once they are reach size limits of
boundaries rather than building ioend chains for later submission.

Did the work for arbitrarily sized bios ever get merged? I can't
find any evidence that it did....

Cheers,

Dave.
--
Dave Chinner
david@fromorbit.com