find out current CPU frequency

Dan Nelson dnelson at allantgroup.com
Mon Apr 7 23:59:24 PDT 2003


In the last episode (Apr 08), Tobias Roth said:
> > > I would like to find out what the current CPU frequency is on my
> > > laptop. I strongly suspect that my laptop, as well as many other
> > > models, pretty much permanently run on degraded performance, even
> > > when under full load.
> > >
> > > At the moment, I use both 4.8 and 5.0 Release with apm, but I plan
> > > to upgrade tocurrent soon.
> 
> > dmesg | grep CPU 
> > Isn't that good enough? Or do you mean after boot?
> 
> no. that is the maximum frequency the cpu runs at, which is fixed.
> with intels speedstep there is a possibility that the cpu runs at a
> lower frequency than that, depending on the current load.
> 
> the idea behind it is this:
> high load -> high freq -> high power consumption, more fan activity
> low load -> lower freq -> lower power consumption, less fan activity
> 
> linprocfs for instance always shows a current cpu freq of
> 1.1something GHZ on my 1.8GHz P4. however I have no idea how
> representative that is.

Check the results of "sysctl hw.acpi.cpu".  If your motherboard
supports it, you should see something like:

hw.acpi.cpu.max_speed: 16
hw.acpi.cpu.current_speed: 16
hw.acpi.cpu.performance_speed: 16
hw.acpi.cpu.economy_speed: 8

max_speed is 100%; anything less sets the CPU sped proportionately
slower.  I have never tried to set hw.acpi.cpu.current_speed=0 :)

-- 
	Dan Nelson
	dnelson at allantgroup.com


More information about the freebsd-questions mailing list