public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [sched] redundant reschedule when set_user_nice() boosts a prio of a task from the "expired" array
@ 2007-04-04 14:04 Dmitry Adamushko
  2007-04-04 14:15 ` Ingo Molnar
  0 siblings, 1 reply; 14+ messages in thread
From: Dmitry Adamushko @ 2007-04-04 14:04 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: Andrew Morton, Linux Kernel

Hello,

Scenario:

Currently running [task1] boosts a priority (lowers a static_prio) of
[task2] via { setpriority -> set_user_nice } and [task2] happens to be
in the "expired" array at the moment.

According to the set_user_nice(), "delta" is negative (the prio is
boosted) and, hence, resched_task(rq->curr) is called.

As the [task2] is in the "expired" array and there are still tasks (at
least [task1]) in the "active" one, the triggered reschedule is just
useless (e.g. gets control back to [task1]).

Am I missing something?

The same is applicable to rt_mutex_setprio().

Of course, not a big deal, but it's easily avoidable, e.g. (delta < 0
&& array == rq->active).

Thanks in advance for any comments.

-- 
Best regards,
Dmitry Adamushko

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2007-04-09  5:54 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-04-04 14:04 [sched] redundant reschedule when set_user_nice() boosts a prio of a task from the "expired" array Dmitry Adamushko
2007-04-04 14:15 ` Ingo Molnar
2007-04-04 15:23   ` Dmitry Adamushko
2007-04-04 20:05   ` [PATCH] " Dmitry Adamushko
2007-04-07  0:03     ` Andrew Morton
2007-04-07  9:16       ` Dmitry Adamushko
2007-04-07  9:24       ` Ingo Molnar
2007-04-07 16:20         ` SD scheduler testing hitch Mike Galbraith
2007-04-07 17:17           ` Mike Galbraith
2007-04-08  8:02             ` Mike Galbraith
2007-04-09  0:14               ` Dmitry Adamushko
2007-04-09  0:23                 ` Dmitry Adamushko
2007-04-09  5:54                   ` Mike Galbraith
2007-04-07  9:19     ` [PATCH] [sched] redundant reschedule when set_user_nice() boosts a prio of a task from the "expired" array Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox