Re: aio stress panic on 2.6.11-mm1

From: Andi Kleen
Date: Wed Mar 09 2005 - 06:18:31 EST


Suparna Bhattacharya <suparna@xxxxxxxxxx> writes:

> Any sense of how costly it is to use spin_lock_irq's vs spin_lock
> (across different architectures) ? Isn't rwsem used very widely ?

On P4s cli/sti is quite costly, let's says 100+ cycles. That is mostly
because it synchronizes the CPU partly. The Intel tables say 26/36 cycles
latency, but in practice it seems to take longer because of the
synchronization.

I would assume this is the worst case, everywhere else it should
be cheaper (except perhaps in some virtualized environments)
On P-M and AMD K7/K8 it is only a few cycles difference.

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