• S
    sched: Remove unlikely() from rt_policy() in sched.c · 63f01241
    Steven Rostedt 提交于
    The rt_policy() has an unlikely() that the policy it is checking is
    of RT priority (SCHED_FIFO or SCHED_RR).
    
    According to the annotate branch profiler it is incorrect most of the time:
    
     correct incorrect  %        Function                  File              Line
     ------- ---------  -        --------                  ----              ----
       36667   654674  94 rt_policy                      sched.c              126
    
    This makes sense because the rt_policy() is used by the sched_set_scheduler()
    and nice(). Although users may use sys_nice a bit, all RT users use
    the sched_set_scheduler() to set their RT priority, including kernel
    threads.
    
    The above numbers were from a normal desktop computer running
    firefox, evolution, xchat and was part of a distcc compile farm.
    
    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Signed-off-by: NSteven Rostedt <rostedt@goodmis.org>
    63f01241
sched.c 226.5 KB