Messages in this thread | | | Date | Mon, 9 Jan 2012 19:14:45 -0500 | From | Youquan Song <> | Subject | Re: [PATCH] x86,sched: Fix sched_smt_power_savings totally broken |
| |
> Yes it is.. also that knob should die! Like i've been saying for way too > long. I'm >< close to committing a patch removing all the power_saving > magic from the scheduler. Sorry. I do not notice it. But currently in many real tests, the knob prove to save power in semi-idle system. They are useful in many user scenarios currently.
> That's the most convoluted way I've seen that stated in a while. What > you're saying is that all threads (of a socket) should be used before > spilling over to another socket. Only touch half. Another half: in ideal, all threads in one core be used before spilling over to another core.
> Hell no, that's completely the wrong thing to do. I think you want to > frob at the group_capacity computation in update_sg_lb_stats. >
Yes. It also can do in the ways you said. I have following testing code before which is changed in update_sg_lb_stats, but there are more refresh code required for fix. Fine, I will base your suggestion to develop another patch soon.
Thanks -Youquan
@@ -3923,6 +3923,10 @@ static inline void update_sg_lb_stats(struct sched_domain *sd, SCHED_POWER_SCALE); if (!sgs->group_capacity) sgs->group_capacity = fix_small_capacity(sd, group); + + if (sched_smt_power_savings) + sgs->group_capacity *= 2; + sgs->group_weight = group->group_weight;
if (sgs->group_capacity > sgs->sum_nr_running)
| |