mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* the value of PROC_CHANGE_PENALTY
@ 2001-06-03 16:06 Tsafrir Dan
  0 siblings, 0 replies; 2+ messages in thread
From: Tsafrir Dan @ 2001-06-03 16:06 UTC (permalink / raw)
  To: linux-kernel; +Cc: etsman, feit

as I understand, for i386 in Linux-2.2.x the default length
of a quantum was 200ms, and in 2.4.x it had changed to 50ms
(
 according to the following 2.4.5 sched.c code:

    #if HZ < 200
    #define TICK_SCALE(x)   ((x) >> 2)
    ...
    #define NICE_TO_TICKS(nice)     (TICK_SCALE(20-(nice))+1)
    ...
    /* in the `recalculate' portion of schedule(): ... */
    for_each_task(p)
        p->counter = (p->counter >> 1) + NICE_TO_TICKS(p->nice);
)

But, 
the value of PROC_CHANGE_PENALTY was not changed accordingly, and is 
still 15. This means that the result of the following goodness() code:
    if (p->processor == this_cpu)
        weight += PROC_CHANGE_PENALTY;
is that any task that executed on `this_cpu' (goodness > 15) 
will always be more "desirable" then a task that executed on 
another cpu (goodness <= 6) which was not the case in 2.2.x .

am I correct ?
and if so, is this what the authors meant, or did they simply forget
to update PROC_CHANGE_PENALTY's value when moving from 2.2 to 2.4 ?

please cc me: dants@cs.huji.ac.il
thanks, dan.

^ permalink raw reply	[flat|nested] 2+ messages in thread
[parent not found: <Pine.LNX.4.10.10106042004010.8516-100000@coffee.psychology.mcmaster.ca>]

end of thread, other threads:[~2001-06-05 19:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-03 16:06 the value of PROC_CHANGE_PENALTY Tsafrir Dan
     [not found] <Pine.LNX.4.10.10106042004010.8516-100000@coffee.psychology.mcmaster.ca>
2001-06-05 19:05 ` Tsafrir Dan

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

all inboxes | Powered by JetHome®