So here's an example of this:
- make all the readers/writers actually update a 64-bit word (by using
cmpxchg8b in user space to actually get the locks)
- but organize things so that a reader only needs to look at the high 32
bits to actually make it's wakeup-decision, and a sleeping writer only
needs to look at the low 32 bits. How? Make the low bits of the words
contain the "contention status".
Is it possible? I dunno. I personally suspect it is. I also suspect you
didn't even try.
Linus
--