Port-amd64 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Wrong CPU frequencies reported by cpu_get_tsc_freq() ?



On Sun, Jul 26, 2015 at 05:26:55PM +0200, Timo Buhrmester wrote:
> > /proc/cpuinfo report wrong CPU frequencies
> The other day I was told that /proc/cpuinfo hasn't been paid attention to in a long time.
> Does cpuctl(8) also report incorrect values?

No this looks correct :

root@raya [~]# cat /proc/cpuinfo
[...]
processor       : 1
vendor_id       : GenuineIntel
cpu family      : 6
model           : 10
model name      : Intel(R) Core(TM) i7-3632QM CPU @ 2.20GHz
stepping        : 9
cpu MHz         : 5000.89
fdiv_bug        : no
fpu             : yes
[...]

root@raya [~]# cpuctl identify 1
cpu1: highest basic info 0000000d
cpu1: highest extended info 80000008
cpu1: "Intel(R) Core(TM) i7-3632QM CPU @ 2.20GHz"
cpu1: Intel Xeon E3-1200v2 and 3rd gen core, Ivy Bridge (686-class),
2195.19 MHz
cpu1: family 0x6 model 0x3a stepping 0x9 (id 0x306a9)
cpu1: features
0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE>
[...]

But, cpuctl(8) uses the very same frequency value for all CPUs,
fetched from "machdep.tsc_freq" sysctl; while procfs cpuinfo use the
CPU specific computed cpu_cc_freq value (with cpu_get_tsc_freq()
function) and stored in the MI per-cpu data member of struct cpu_info.

-- 
Nicolas Joly

Computing Group
Biology IT Center
Institut Pasteur, Paris.


Home | Main Index | Thread Index | Old Index