optimize vruntime based scheduling.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Mike Galbraith <efault@gmx.de>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
 static inline void update_load_add(struct load_weight *lw, unsigned long inc)
 {
        lw->weight += inc;
-       lw->inv_weight = WMULT_CONST / lw->weight;
+       if (sched_feat(FAIR_SLEEPERS))
+               lw->inv_weight = WMULT_CONST / lw->weight;
 }
 
 static inline void update_load_sub(struct load_weight *lw, unsigned long dec)
 {
        lw->weight -= dec;
-       if (likely(lw->weight))
+       if (sched_feat(FAIR_SLEEPERS) && likely(lw->weight))
                lw->inv_weight = WMULT_CONST / lw->weight;
 }
 
 
        }
        curr->vruntime += delta_exec_weighted;
 
+       if (!sched_feat(FAIR_SLEEPERS))
+               return;
+
        if (unlikely(!load))
                return;