Re: [rfc][patch] remove racy sync_page?

From: Nick Piggin
Date: Wed May 31 2006 - 09:28:52 EST


Linus Torvalds wrote:

On Wed, 31 May 2006, Nick Piggin wrote:

The requests can only get merged if contiguous requests from the upper
layers come down, right?


It has nothing to do with merging. It has to do with IO patterns.

Seeking.

Seeking is damn expensive - much more so than command issue. People forget that sometimes.

OK, I didn't forget that it is expensive, but I didn't make the
connection that this is what you were arguing for.

I would be surprised if plugging made a big difference to seeking:
1. the queue will be plugged only if there are no other requests (so,
nothing else to seek to).
2. if the queue was plugged and we submitted one small request,
another request to somewhere else on the drive that comes in can
itself unplug the queue and cause seeking.

as-iosched is good at cutting down seeks because it doesn't "unplug"
in situation #2.

Now having a mechanism for a task to batch up requests might be a
good idea. Eg.

plug();
submit reads
unplug();
wait for page

I'd think this would give us the benefits of corse grained (per-queue)
plugging and more (e.g. it works when the request queue isn't empty).
And it would be simpler because the unplug point is explicit and doesn't
need to be kicked by lock_page or wait_on_page

--
SUSE Labs, Novell Inc.
Send instant messages to your online friends http://au.messenger.yahoo.com -
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/