Re: [PATCH] io stalls (was: -rc7 Re: Linux 2.4.21-rc6)

From: Andrea Arcangeli (andrea@suse.de)
Date: Wed Jun 11 2003 - 13:12:17 EST


On Wed, Jun 11, 2003 at 01:42:41PM -0400, Chris Mason wrote:
> + if (q->rq[rw].count >= q->batch_requests) {
> + smp_mb();
> + if (waitqueue_active(&q->wait_for_requests[rw]))
> + wake_up(&q->wait_for_requests[rw]);

in my tree I also changed this to:

                                wake_up_nr(&q->wait_for_requests[rw], q->rq[rw].count);

otherwise only one waiter will eat the requests, while multiple waiters
can eat requests in parallel instead because we freed not just 1 request
but many of them.

I wonder if my above change is really the right way to implement the
removal of the _exclusive line that went in rc6. However with your patch
the wake_up_nr (or ~equivalent removal of _exclusive wakeup of rc6)
should mostly improve cpu parallelism in smp and while waiting for I/O,
the amount of stuff in the I/O queue and the overall fariness shouldn't
change very significantly with this new completely fair FIFO request
allocator.

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



This archive was generated by hypermail 2b29 : Sun Jun 15 2003 - 22:00:28 EST