Re: [GIT PULL] Ext3 latency fixes

From: Jens Axboe
Date: Mon Apr 06 2009 - 02:26:08 EST


On Sun, Apr 05 2009, Linus Torvalds wrote:
>
>
> On Sun, 5 Apr 2009, Arjan van de Ven wrote:
> >
> > > See get_request():
> >
> > our default number of requests is so low that we very regularly hit the
> > limit. In addition to setting kjournald to higher priority, I tend to
> > set the number of requests to 4096 or so to improve interactive
> > performance on my own systems. That way at least the elevator has a
> > chance to see the requests ;-)
>
> That's insane. Long queues make the problem harder to hit, yes. But it
> also tends to make the problem them a million times worse when you _do_
> hit it.

Unfortunately it is insane, because the vm will barf big time on that.
Perhaps when we do the "throttle at device IO rate" for dirtying of data
we can be more relaxed, but increasing nr_requests too much will just
cause the vm to go nuts.

> I would suggest looking instead at trying to have separate allocation
> pools for bulk and "sync" IO. Instead of having just one rq->rq_pool, we
> could easily have a rq->rq_bulk_pool and rq->rq_sync_pool.
>
> We might even _save_ memory by having two pools simply because that may
> make it much less important to have a big pool. Most subsystems don't
> really need that many requests in flight anyway, and the advantage to the
> elevator of huge pools is rather dubious.

The pools are not big, the number is just a maximum allocation number.
In reality we only store 4 requests in the mempool, and we should
probably just dump that down to 1.

--
Jens Axboe

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/