lkml.org 
[lkml]   [2001]   [Oct]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Context switch times
    On Sun, Oct 07, 2001 at 12:57:29PM +0300, Mika Liljeberg wrote:
    > For problems 1 and 2 I propose the following solution: Insert the the
    > load balancing routine itself as a (fake) task on each CPU and run it
    > when the CPU gets around to it. The load balancer should behave almost
    > like a CPU-bound task, scheduled on the lowest priority level with other
    > runnable tasks.

    The idle-task might be (ab-)used for this, because it has perfect
    data for this.

    T_SystemElapsed - T_IdleTaskRun = T_CPULoaded

    Balancing could be done in schedule() itself, after checking this
    value for each CPU.

    > The last bit is important: the load balancer should not
    > be allowed to starve but should be invoked approximately once every
    > "full rotation" of the scheduler.

    If a artificial CPU-hog is used for this task, the idle task will
    never be run and power savings in the CPU are impossible.

    Other parts sound interesting.

    Regards

    Ingo Oeser
    --
    .... Our continuing mission: To seek out knowledge of C, to explore
    strange UNIX commands, and to boldly code where no one has man page 4.
    --- Mike A. Harris <mharris@meteng.on.ca>
    -
    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/

    \
     
     \ /
      Last update: 2005-03-22 13:04    [W:5.107 / U:2.128 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site