lkml.org 
[lkml]   [2019]   [Dec]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Running an Ivy Bridge cpu at fixed frequency
On Wed, Dec 04, 2019 at 05:01:32PM +0000, David Laight wrote:
> Is there any way to persuade the intel_pstate driver to make an Ivy bridge (i7-3770)
> cpu run at a fixed frequency?

You can, use performance governor and put scaling_{min,max}_freq at the
base_frequency (I _think_, I never quite remember if that is the max non
turbo P state).

If that doesn't work, simply put it at cpuinfo_min_freq. It's slow, but
it's guaranteed stable.

> It is really difficult to compare code execution times when the cpu clock speed
> keeps changing.

As Andy already wrote, perf is really good for this.

Find attached, it probably is less shiny than what Andy handed you, but
contains all the bits required to frob something.

> I thought I'd managed by setting the 'scaling_max_freq' to 1.7GHz, but even that
> doesn't seem to be working now.

You also have to set the min I think, and select the performance
governor, otherwise it's too tempted to be 'smart' about stuff.

> It would also be nice to run a little faster than that - but without it 'randomly'
> going to 'turbo' frequencies (which it is doing even after I've set no_turbo to 1).
>
> An alternative would be a variable frequency TSC - might give more consistent values.

perf :-)
[unhandled content-type:application/octet-stream]
\
 
 \ /
  Last update: 2019-12-05 10:45    [W:0.063 / U:1.288 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site