| Date | Sat, 14 Apr 2007 08:32:54 +0200 | From | Ingo Molnar <> | Subject | Re: [Announce] [patch] Modular Scheduler Core and Completely Fair Scheduler [CFS] |
| |
* Nick Piggin <npiggin@suse.de> wrote:
> > The CFS patch uses a completely different approach and implementation > > from RSDL/SD. My goal was to make CFS's interactivity quality exceed > > that of RSDL/SD, which is a high standard to meet :-) Testing > > feedback is welcome to decide this one way or another. [ and, in any > > case, all of SD's logic could be added via a kernel/sched_sd.c module > > as well, if Con is interested in such an approach. ] > > Comment about the code: shouldn't you be requeueing the task in the > rbtree wherever you change wait_runtime? eg. task_new_fair? [...]
yes: the task's position within the rbtree is updated every time wherever wait_runtime is change. task_new_fair is the method during new task creation, but indeed i forgot to requeue the parent. I've fixed this in my tree (see the delta patch below) - thanks!
Ingo
-----------> From: Ingo Molnar <mingo@elte.hu> Subject: [cfs] fix parent's rbtree position
Nick noticed that upon fork we change parent->wait_runtime but we do not requeue it within the rbtree.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Index: linux/kernel/sched_fair.c =================================================================== --- linux.orig/kernel/sched_fair.c +++ linux/kernel/sched_fair.c @@ -524,6 +524,8 @@ static void task_new_fair(struct rq *rq, p->wait_runtime = parent->wait_runtime/2; parent->wait_runtime /= 2; + requeue_task_fair(rq, parent); + /* * For the first timeslice we allow child threads * to move their parent-inherited fairness back - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
|