Re: [RFC] Repeated rto_push_irq_work_func() invocation.

From: Steven Rostedt
Date: Wed Oct 02 2024 - 11:54:44 EST


On Wed, 2 Oct 2024 17:35:00 +0200
Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx> wrote:

> > Hmm, I probably should look deeper to make sure that anytime a schedule
> > happens where there's overloaded RT tasks, it tries to push.
>
> I think it tried pull on schedule but then it got outsourced to push via
> the IPI with this new code. Don't remember the details

Pull is much more expensive than push. That's because we keep track of the
"cpuprio" which is the priority of tasks running on each CPU. To do a push,
you simply look for the CPU running the lowest priority task using the
cpuprio logic and send the task there.

For a pull, we have no idea which is the highest priority RT task that is
waiting. We originally did a search of all the CPUs with overloaded RT
tasks, but this search takes way to long, and since it's done in the
scheduler, it caused high latency. Which is what the IPI dance is trying to
mitigate.

-- Steve