Re: [block IO crash] Re: 2.6.39-rc5-git2 boot crashs

From: Ingo Molnar
Date: Thu May 05 2011 - 15:14:22 EST



* Christoph Lameter <cl@xxxxxxxxx> wrote:

> On Thu, 5 May 2011, Tejun Heo wrote:
>
> > Anyways, that's what I've been thinking. I'll get to it in the next
> > devel cycle or the one after that. What do you guys think about soft
> > irq masking idea?
>
> Great idea. Would make the whole irq on/off business much cheaper.

The tradeoffs are *not at all* clear and the result (on x86) is not
'much cheaper', at all ...

In particular the irq-enable path gets complicated by the need to check the
flag and call a hardirq handling function in that case - a far cry from the
single-byte POPF instruction. It will be somewhat cheaper cycle-wise - but the
code gets bloated, so the instruction cache impact has to be measured
carefully. (See my other mail for details.)

There's also the fact that PUSHF+CLI+POPF sequence has been getting cheaper all
the time with newer hardware generations. CLI+STI is even cheaper, 10 cycles
both on Intel and AMD CPUs. So it's an optimization that might get narrower and
narrower with every CPU generation.

Thanks,

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/