Re: [RFC PATCHSET] sched,perf: unify tracers in sched and move perf on top of TP

Tejun Heo
2010-05-06T08:42:16Z

Hello, Ingo.

On 05/06/2010 10:27 AM, Ingo Molnar wrote:
> Note that preempt notifiers used to modify scheduling behavior/semantics i'm
> really against. Please get that functionality into the scheduler - especially
> if it's essentially always-on.

Okay. Well, cmwq's usage of it isn't that hairy. It's used for two
things.

1. to count the number of currently running workers which I think is
fine for such hooks.

2. to wake up another worker. I don't think this falls in the
category of "behavior/semantics" change. It just does
try_to_wake_up() with the only caveat being it's called under the
rq lock so requires a different API. There's nothing which alters
the scheduler behavior in any pervasive way. It just looks at the
counter and wakes up another task if the condition is right
*before* beginning any of real scheduling work.

But, anyways, making a dedicated fixed function calls certainly isn't
a problem and might as well be slightly cheaper as it's always gonna
be there anyway. If that's preferred, I'll happily take that path.

Thanks.

--
tejun