Re: [patch 0/3] j_state_lock, j_list_lock, remove-bitlocks

From: Ingo Molnar
Date: Wed Mar 16 2005 - 05:21:48 EST



* Andrew Morton <akpm@xxxxxxxx> wrote:

> > > There's a little lock ranking diagram in jbd.h which tells us that
> > > these locks nest inside j_list_lock and j_state_lock. So I guess
> > > you'll need to turn those into semaphores.
> >
> > indeed. I did this (see the three followup patches, against BK-curr),
> > and it builds/boots/works just fine on an ext3 box. Do we want to try
> > this in -mm?
>
> ooh, I'd rather not. I spent an intense three days removing all the
> sleeping locks from ext3 (and three months debugging the result).
> Ended up gaining 1000% on 16-way.
>
> Putting them back in will really hurt the SMP performance.

seems like turning the bitlocks into spinlocks is the best option then.
We'd need one lock in buffer_head (j_state_lock, renamed to something
more sensible like b_private_lock), and one lock in journal_head
(j_list_lock) i guess. How much would the +4/+8 bytes size increase in
buffer_head [on SMP] be frowned upon?

Ingo
-
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/