Commit 75d2e44e authored by Len Brown's avatar Len Brown

tools/power turbostat: re-name "%Busy" field to "Busy%"

some tools processing turbostat output
have difficulty with items that begin with %...
Reported-by: default avatarJacob Pan <jacob.jun.pan@linux.intel.com>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent cbf97aba
...@@ -61,7 +61,7 @@ displays the statistics gathered since it was forked. ...@@ -61,7 +61,7 @@ displays the statistics gathered since it was forked.
.nf .nf
\fBCPU\fP Linux CPU (logical processor) number. Yes, it is okay that on many systems the CPUs are not listed in numerical order -- for efficiency reasons, turbostat runs in topology order, so HT siblings appear together. \fBCPU\fP Linux CPU (logical processor) number. Yes, it is okay that on many systems the CPUs are not listed in numerical order -- for efficiency reasons, turbostat runs in topology order, so HT siblings appear together.
\fBAVG_MHz\fP number of cycles executed divided by time elapsed. \fBAVG_MHz\fP number of cycles executed divided by time elapsed.
\fB%Busy\fP percent of the interval that the CPU retired instructions, aka. % of time in "C0" state. \fBBusy%\fP percent of the interval that the CPU retired instructions, aka. % of time in "C0" state.
\fBBzy_MHz\fP average clock rate while the CPU was busy (in "c0" state). \fBBzy_MHz\fP average clock rate while the CPU was busy (in "c0" state).
\fBTSC_MHz\fP average MHz that the TSC ran during the entire interval. \fBTSC_MHz\fP average MHz that the TSC ran during the entire interval.
.fi .fi
...@@ -89,7 +89,7 @@ Without any parameters, turbostat displays statistics ever 5 seconds. ...@@ -89,7 +89,7 @@ Without any parameters, turbostat displays statistics ever 5 seconds.
for turbostat to fork). for turbostat to fork).
.nf .nf
[root@hsw]# ./turbostat [root@hsw]# ./turbostat
CPU Avg_MHz %Busy Bzy_MHz TSC_MHz CPU Avg_MHz Busy% Bzy_MHz TSC_MHz
- 488 12.51 3898 3498 - 488 12.51 3898 3498
0 0 0.01 3885 3498 0 0 0.01 3885 3498
4 3897 99.99 3898 3498 4 3897 99.99 3898 3498
...@@ -145,7 +145,7 @@ cpu0: MSR_IA32_THERM_STATUS: 0x88340000 (48 C +/- 1) ...@@ -145,7 +145,7 @@ cpu0: MSR_IA32_THERM_STATUS: 0x88340000 (48 C +/- 1)
cpu1: MSR_IA32_THERM_STATUS: 0x88440000 (32 C +/- 1) cpu1: MSR_IA32_THERM_STATUS: 0x88440000 (32 C +/- 1)
cpu2: MSR_IA32_THERM_STATUS: 0x88450000 (31 C +/- 1) cpu2: MSR_IA32_THERM_STATUS: 0x88450000 (31 C +/- 1)
cpu3: MSR_IA32_THERM_STATUS: 0x88490000 (27 C +/- 1) cpu3: MSR_IA32_THERM_STATUS: 0x88490000 (27 C +/- 1)
Core CPU Avg_MHz %Busy Bzy_MHz TSC_MHz SMI CPU%c1 CPU%c3 CPU%c6 CPU%c7 CoreTmp PkgTmp PkgWatt CorWatt GFXWatt Core CPU Avg_MHz Busy% Bzy_MHz TSC_MHz SMI CPU%c1 CPU%c3 CPU%c6 CPU%c7 CoreTmp PkgTmp PkgWatt CorWatt GFXWatt
- - 493 12.64 3898 3498 0 12.64 0.00 0.00 74.72 47 47 21.62 13.74 0.00 - - 493 12.64 3898 3498 0 12.64 0.00 0.00 74.72 47 47 21.62 13.74 0.00
0 0 4 0.11 3894 3498 0 99.89 0.00 0.00 0.00 47 47 21.62 13.74 0.00 0 0 4 0.11 3894 3498 0 99.89 0.00 0.00 0.00 47 47 21.62 13.74 0.00
0 4 3897 99.98 3898 3498 0 0.02 0 4 3897 99.98 3898 3498 0 0.02
...@@ -178,7 +178,7 @@ until ^C while the other CPUs are mostly idle: ...@@ -178,7 +178,7 @@ until ^C while the other CPUs are mostly idle:
.nf .nf
root@hsw: turbostat cat /dev/zero > /dev/null root@hsw: turbostat cat /dev/zero > /dev/null
^C ^C
CPU Avg_MHz %Busy Bzy_MHz TSC_MHz CPU Avg_MHz Busy% Bzy_MHz TSC_MHz
- 482 12.51 3854 3498 - 482 12.51 3854 3498
0 0 0.01 1960 3498 0 0 0.01 1960 3498
4 0 0.00 2128 3498 4 0 0.00 2128 3498
...@@ -192,12 +192,12 @@ root@hsw: turbostat cat /dev/zero > /dev/null ...@@ -192,12 +192,12 @@ root@hsw: turbostat cat /dev/zero > /dev/null
.fi .fi
Above the cycle soaker drives cpu5 up its 3.9 GHz turbo limit. Above the cycle soaker drives cpu5 up its 3.9 GHz turbo limit.
The first row shows the average MHz and %Busy across all the processors in the system. The first row shows the average MHz and Busy% across all the processors in the system.
Note that the Avg_MHz column reflects the total number of cycles executed Note that the Avg_MHz column reflects the total number of cycles executed
divided by the measurement interval. If the %Busy column is 100%, divided by the measurement interval. If the Busy% column is 100%,
then the processor was running at that speed the entire interval. then the processor was running at that speed the entire interval.
The Avg_MHz multiplied by the %Busy results in the Bzy_MHz -- The Avg_MHz multiplied by the Busy% results in the Bzy_MHz --
which is the average frequency while the processor was executing -- which is the average frequency while the processor was executing --
not including any non-busy idle time. not including any non-busy idle time.
...@@ -233,7 +233,7 @@ in the brand string in /proc/cpuinfo. On a system where ...@@ -233,7 +233,7 @@ in the brand string in /proc/cpuinfo. On a system where
the TSC stops in idle, TSC_MHz will drop the TSC stops in idle, TSC_MHz will drop
below the processor's base frequency. below the processor's base frequency.
%Busy = MPERF_delta/TSC_delta Busy% = MPERF_delta/TSC_delta
Bzy_MHz = TSC_delta/APERF_delta/MPERF_delta/measurement_interval Bzy_MHz = TSC_delta/APERF_delta/MPERF_delta/measurement_interval
......
...@@ -293,7 +293,7 @@ int get_msr(int cpu, off_t offset, unsigned long long *msr) ...@@ -293,7 +293,7 @@ int get_msr(int cpu, off_t offset, unsigned long long *msr)
/* /*
* Example Format w/ field column widths: * Example Format w/ field column widths:
* *
* Package Core CPU Avg_MHz Bzy_MHz TSC_MHz SMI %Busy CPU_%c1 CPU_%c3 CPU_%c6 CPU_%c7 CoreTmp PkgTmp Pkg%pc2 Pkg%pc3 Pkg%pc6 Pkg%pc7 PkgWatt CorWatt GFXWatt * Package Core CPU Avg_MHz Bzy_MHz TSC_MHz SMI Busy% CPU_%c1 CPU_%c3 CPU_%c6 CPU_%c7 CoreTmp PkgTmp Pkg%pc2 Pkg%pc3 Pkg%pc6 Pkg%pc7 PkgWatt CorWatt GFXWatt
* 123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678 * 123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678123456781234567812345678
*/ */
...@@ -308,7 +308,7 @@ void print_header(void) ...@@ -308,7 +308,7 @@ void print_header(void)
if (has_aperf) if (has_aperf)
outp += sprintf(outp, " Avg_MHz"); outp += sprintf(outp, " Avg_MHz");
if (has_aperf) if (has_aperf)
outp += sprintf(outp, " %%Busy"); outp += sprintf(outp, " Busy%%");
if (has_aperf) if (has_aperf)
outp += sprintf(outp, " Bzy_MHz"); outp += sprintf(outp, " Bzy_MHz");
outp += sprintf(outp, " TSC_MHz"); outp += sprintf(outp, " TSC_MHz");
...@@ -511,7 +511,7 @@ int format_counters(struct thread_data *t, struct core_data *c, ...@@ -511,7 +511,7 @@ int format_counters(struct thread_data *t, struct core_data *c,
outp += sprintf(outp, "%8.0f", outp += sprintf(outp, "%8.0f",
1.0 / units * t->aperf / interval_float); 1.0 / units * t->aperf / interval_float);
/* %Busy */ /* Busy% */
if (has_aperf) { if (has_aperf) {
if (!skip_c0) if (!skip_c0)
outp += sprintf(outp, "%8.2f", 100.0 * t->mperf/t->tsc/tsc_tweak); outp += sprintf(outp, "%8.2f", 100.0 * t->mperf/t->tsc/tsc_tweak);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment