Re: Read/write locks

David S. Miller (davem@jenolan.rutgers.edu)
Sun, 21 Sep 1997 04:31:22 -0400


Date: Sun, 21 Sep 1997 02:23:37 -0600 (MDT)
From: Colin Plumb <colin@nyx.net>

Just wondering... whose words are quoted with ":"? I haven't
seen tiwr writing directly...

That was my way of presenting my commentary.

I blurted all of that out from memory, and forgot the crucial part
which made my analysis incorrect. The problem is that all the other
implementations only allow an "upgrade" to be done as an attempt
(ie. it can fail, just like spin_trylock()) by all readers, which
falls into the "optimistic" locking strategy you have been mentioning.
Duh, can't believe I missed this one.

Anyways, with that I still have one final gripe with the upgrader
scheme. It makes the locks fatter, and Linux already blows the L2
cache to shreds on most platforms as it is...

Later,
David "Sparc" Miller
davem@caip.rutgers.edu