Re: [PATCH 1/1] intel_pstate: Increase hold-off time before busyness is scaled

From: Mel Gorman
Date: Tue Feb 23 2016 - 09:05:12 EST


On Thu, Feb 18, 2016 at 01:09:26PM -0800, Doug Smythies wrote:
> >> +++ b/drivers/cpufreq/intel_pstate.c
> >> @@ -999,7 +999,7 @@ static inline int32_t get_target_pstate_use_performance(struct cpudata *cpu)
> >> sample_time = pid_params.sample_rate_ms * USEC_PER_MSEC;
> >> duration_us = ktime_us_delta(cpu->sample.time,
> >> cpu->last_sample_time);
> >> - if (duration_us > sample_time * 3) {
> >> + if (duration_us > sample_time * 12) {
> >> sample_ratio = div_fp(int_tofp(sample_time),
> >> int_tofp(duration_us));
> >> core_busy = mul_fp(core_busy, sample_ratio);
> >> --
>
> The immediately preceding comment needs to be changed also.
> Note that with duration related scaling only coming in at such a high
> ratio it might be worth saving the divide and just setting it to 0.
>

I tried this and FWIW, the performance is generally comparable as is the
power usage as reported by turbostat. On occasion, depending on the
machine, the system CPU usage is noticably lower.

--
Mel Gorman
SUSE Labs