Re: [RFC][PATCH 0/5] Signal scalability series
From: Peter Zijlstra
Date: Mon Oct 03 2011 - 11:23:36 EST
On Mon, 2011-10-03 at 15:07 +0200, Oleg Nesterov wrote:
> On 10/01, Peter Zijlstra wrote:
> But this series can't help afaics. At least in its current state. It
> only adds more locking to the sending paths.
Right, so I was hoping Matt had a plan (TM)... :-)
> And anyway it is wrong (afaics, and I didn't read it yet ;).
I'll leave you to be the judge of that, I haven't bent by brain around
all this signal stuff yet..
> > which precludes being able
> > to deliver signals from hardirq context, leading to lots of ugly in -rt.
> I think, the best solution would be: never send the signal from irq
> context, and ->siglock shouldn't disable irqs.
Bit hard that, posix timers need to deliver signals which pretty much
mandates we do something from irq context (and the round-trip through
softirq context really isn't pretty nor good for performance).
> > The hope is that this work is a stepping stone to O(1) signal delivery.
> Probably this is possible too. I was thinking anout this when
> set_current_blocked() was added. Unfortunately this needs a lot of
Right, so the thing Thomas and I have been promoting for a while now is
to update a signal target vector on every signal mask update. Mask
updates should be the slow path. This would leave us with a ready target
Although given that we've promoted this idea for a while now and it
hasn't happened yet I'm sure its non-trivial :-)
> > Breaking up the multitude of uses of siglock certainly seems worthwhile
> > esp.
> Agreed. But I am not sure how much we should split the locking when
> it comes to sending/dequeueing/etc signals. 5 locks seems too much.
It doesn't need all 5 locks to send a signal, does it? But then, I'm
somewhat out of my depth here, the whole signal delivery path always
> > And yes, aside from that the siglock can be quite contended because its
> > pretty much the one lock serializing all of the process wide state.
> Mostly this is because we moved misc stuff from tasklist to siglock,
> previously this was a win. Today this doesn't look good.
Well a per-process lock still wins from a global lock, but yeah, it
wants to be broken up further.
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/