]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
tools/power turbostat: Denverton: use HW CC1 counter, skip C3, C7
authorLen Brown <len.brown@intel.com>
Fri, 27 Jan 2017 07:13:27 +0000 (02:13 -0500)
committerLen Brown <len.brown@intel.com>
Wed, 1 Mar 2017 05:14:20 +0000 (00:14 -0500)
commit7170a374377d7c70d63a2d3eb38f8fe32e6ffadd
treef10afcda859f78591d2a9802e573ede124965142
parentac01ac1371d01beb02827f89fff9aac9d7941e91
tools/power turbostat: Denverton: use HW CC1 counter, skip C3, C7

The CC1 column in tubostat can be computed by subtracting
the core c-state residency countes from the total Cx residency.

CC1 = (Idle_time_as_measured by MPERF) - (all core C-states with
residency counters)

However, as the underlying counter reads are not atomic,
error can be noticed in this calculations, especially
when the numbers are small.

Denverton has a hardware CC1 residency counter
to improve the accuracy of the cc1 statistic -- use it.

At the same time, Denverton has no concept of CC3, PC3, CC7, PC7,
so skip collecting and printing those columns.

Finally, a note of clarification.
Turbostat prints the standard PC2 residency counter,
but on Denverton hardware, that actually means PC1E.
Turbostat prints the standard PC6 residency counter,
but on Denverton hardware, that actually means PC2.

At this point, we document that differnce in this commit message,
rather than adding a quirk to the software.

Signed-off-by: Len Brown <len.brown@intel.com>
tools/power/x86/turbostat/turbostat.c