[lkml]   [2009]   [Jun]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH RFC] softirq: fix ksoftirq starved
    Ingo Molnar wrote:
    > * Lai Jiangshan <> wrote:
    >> --- a/kernel/sched.c
    >> +++ b/kernel/sched.c
    >> @@ -5307,6 +5307,7 @@ need_resched:
    >> release_kernel_lock(prev);
    >> need_resched_nonpreemptible:
    >> + schedule_softirq_check();
    >> schedule_debug(prev);
    > hm, this slows down the scheduler fast-path ...
    > Ingo

    It's true. But:

    The overheads are:

    Overhead-A: the function call statement "schedule_softirq_check();"
    It can be gotten rid off by a macro or inline function.

    Overhead-B: __get_cpu_var() and the test statement.

    Overhead-C: do_softirq()
    In my patch, we test a variable and then call do_softirq() when
    the variable is true. do_softirq() can be called from process
    context or from schedule() or by any other ways, but it must be
    called and avoids starvation in this condition.
    So we need pay this overhead. It is no worse than before.

    Is it a critical thing when it slows down the scheduler fast-path
    because of the "Overhead-B"?

    Or I misunderstand something?

    Thanks, Lai.

     \ /
      Last update: 2009-06-18 05:21    [W:0.019 / U:8.368 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site