Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1358587
| From | Peter Zijlstra <peterz@infradead.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization |
| Date | 2016-03-16 08:40 +0100 |
| Message-ID | <rdedI-5Je-39@gated-at.bofh.it> (permalink) |
| References | <rcteN-7Q2-3@gated-at.bofh.it> <rcteN-7Q2-1@gated-at.bofh.it> <rd4R3-7Rt-7@gated-at.bofh.it> <rdedJ-5Je-41@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, Mar 15, 2016 at 03:09:51PM -0700, Michael Turquette wrote:
> Quoting Peter Zijlstra (2016-03-15 14:29:26)
> > On Sun, Mar 13, 2016 at 10:22:10PM -0700, Michael Turquette wrote:
> >
> > > +static unsigned long sugov_sum_total_util(struct sugov_cpu *sg_cpu)
> > > +{
> > > + enum sched_class_util sc;
> > > +
> > > + /* sum the utilization of all sched classes */
> > > + sg_cpu->total_util = 0;
> > > + for (sc = 0; sc < nr_util_types; sc++)
> > > + sg_cpu->total_util += sg_cpu->util[sc];
> > > +
> > > + return sg_cpu->total_util;
> > > +}
> >
> > > @@ -153,7 +172,7 @@ static unsigned int sugov_next_freq(struct sugov_policy *sg_policy,
> > > if ((s64)delta_ns > NSEC_PER_SEC / HZ)
> > > continue;
> > >
> > > - j_util = j_sg_cpu->util;
> > > + j_util = j_sg_cpu->total_util;
> > > j_max = j_sg_cpu->max;
> > > if (j_util > j_max)
> > > return max_f;
> >
> > So while not strictly wrong, I think we can do so much better.
> >
> > Changelog doesn't mention anything useful, like that this is indeed very
> > rough and what we really should be doing etc..
>
> What should we really be doing? Summing the scheduler class
> contributions seems correct to me.
>
> Are you referring to the fact that dl and rt are passing bogus values
> into cpufreq_update_util()? If so I'm happy to add a note about that in
> the changelog.
Somewhere in the giant discussions I mentioned that we should be looking
at a CPPC like interface and pass {min,max} tuples to the cpufreq
selection thingy.
In that same discussion I also mentioned that we must compute min as the
hard dl reservation, but that for max we can actually use the avg dl +
avg rt + avg cfs.
That way there is far more room for selecting a sensible frequency.
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization Michael Turquette <mturquette@baylibre.com> - 2016-03-14 06:30 +0100
Re: [PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization Peter Zijlstra <peterz@infradead.org> - 2016-03-15 22:40 +0100
Re: [PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization Peter Zijlstra <peterz@infradead.org> - 2016-03-16 08:40 +0100
Re: [PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization Steve Muckle <steve.muckle@linaro.org> - 2016-03-16 19:30 +0100
Re: [PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization Peter Zijlstra <peterz@infradead.org> - 2016-03-16 19:40 +0100
Re: [PATCH 6/8] cpufreq/schedutil: sum per-sched class utilization Steve Muckle <steve.muckle@linaro.org> - 2016-03-16 20:20 +0100
csiph-web