~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/tools/power/x86/turbostat/turbostat.8

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /tools/power/x86/turbostat/turbostat.8 (Version linux-6.12-rc7) and /tools/power/x86/turbostat/turbostat.8 (Version linux-4.12.14)


  1 .TH TURBOSTAT 8                                     1 .TH TURBOSTAT 8
  2 .SH NAME                                            2 .SH NAME
  3 turbostat \- Report processor frequency and id      3 turbostat \- Report processor frequency and idle statistics
  4 .SH SYNOPSIS                                        4 .SH SYNOPSIS
  5 .ft B                                               5 .ft B
  6 .B turbostat                                        6 .B turbostat
  7 .RB [ Options ]                                     7 .RB [ Options ]
  8 .RB command                                         8 .RB command
  9 .br                                                 9 .br
 10 .B turbostat                                       10 .B turbostat
 11 .RB [ Options ]                                    11 .RB [ Options ]
 12 .RB [ "\--interval seconds" ]                      12 .RB [ "\--interval seconds" ]
 13 .SH DESCRIPTION                                    13 .SH DESCRIPTION
 14 \fBturbostat \fP reports processor topology, f     14 \fBturbostat \fP reports processor topology, frequency,
 15 idle power-state statistics, temperature and p     15 idle power-state statistics, temperature and power on X86 processors.
 16 There are two ways to invoke turbostat.            16 There are two ways to invoke turbostat.
 17 The first method is to supply a                    17 The first method is to supply a
 18 \fBcommand\fP, which is forked and statistics      18 \fBcommand\fP, which is forked and statistics are printed
 19 in one-shot upon its completion.                   19 in one-shot upon its completion.
 20 The second method is to omit the command,          20 The second method is to omit the command,
 21 and turbostat displays statistics every 5 seco     21 and turbostat displays statistics every 5 seconds interval.
 22 The 5-second interval can be changed using the     22 The 5-second interval can be changed using the --interval option.
 23 .PP                                                23 .PP
 24 Some information is not available on older pro     24 Some information is not available on older processors.
 25 .SS Options                                        25 .SS Options
 26 Options can be specified with a single or doub     26 Options can be specified with a single or double '-', and only as much of the option
 27 name as necessary to disambiguate it from othe     27 name as necessary to disambiguate it from others is necessary.  Note that options are case-sensitive.
 28 .PP                                                28 .PP
 29 \fB--add attributes\fP add column with counter     29 \fB--add attributes\fP add column with counter having specified 'attributes'.  The 'location' attribute is required, all others are optional.
 30 .nf                                                30 .nf
 31         location: {\fBmsrDDD\fP | \fBmsr0xXXX\ !!  31         location: {\fBmsrDDD\fP | \fBmsr0xXXX\fP | \fB/sys/path...\fP}
 32                 msrDDD is a decimal offset, eg     32                 msrDDD is a decimal offset, eg. msr16
 33                 msr0xXXX is a hex offset, eg.      33                 msr0xXXX is a hex offset, eg. msr0x10
 34                 /sys/path... is an absolute pa     34                 /sys/path... is an absolute path to a sysfs attribute
 35                 <device> is a perf device from << 
 36                 <event> is a perf event for gi << 
 37                         perf/cstate_core/c1-re << 
 38                                                    35 
 39         scope: {\fBcpu\fP | \fBcore\fP | \fBpa     36         scope: {\fBcpu\fP | \fBcore\fP | \fBpackage\fP}
 40                 sample and print the counter f     37                 sample and print the counter for every cpu, core, or package.
 41                 default: cpu                       38                 default: cpu
 42                                                    39 
 43         size: {\fBu32\fP | \fBu64\fP }             40         size: {\fBu32\fP | \fBu64\fP }
 44                 MSRs are read as 64-bits, u32      41                 MSRs are read as 64-bits, u32 truncates the displayed value to 32-bits.
 45                 default: u64                       42                 default: u64
 46                                                    43 
 47         format: {\fBraw\fP | \fBdelta\fP | \fB     44         format: {\fBraw\fP | \fBdelta\fP | \fBpercent\fP}
 48                 'raw' shows the MSR contents i     45                 'raw' shows the MSR contents in hex.
 49                 'delta' shows the difference i     46                 'delta' shows the difference in values during the measurement interval.
 50                 'percent' shows the delta as a     47                 'percent' shows the delta as a percentage of the cycles elapsed.
 51                 default: delta                     48                 default: delta
 52                                                    49 
 53         name: "name_string"                        50         name: "name_string"
 54                 Any string that does not match     51                 Any string that does not match a key-word above is used
 55                 as the column header.              52                 as the column header.
 56 .fi                                                53 .fi
 57 .PP                                                54 .PP
 58 \fB--add pmt,[attr_name=attr_value, ...]\fP ad << 
 59 .nf                                            << 
 60         name="name_string"                     << 
 61                 For column header.             << 
 62                                                << 
 63         type={\fBraw\fP}                       << 
 64                 'raw' shows the counter conten << 
 65                 default: raw                   << 
 66                                                << 
 67         format={\fBraw\fP | \fBdelta\fP}       << 
 68                 'raw' shows the counter conten << 
 69                 'delta' shows the difference i << 
 70                 default: raw                   << 
 71                                                << 
 72         domain={\fBcpu%u\fP | \fBcore%u\fP | \ << 
 73                 'cpu' per cpu/thread counter.  << 
 74                 'core' per core counter.       << 
 75                 'package' per package counter. << 
 76                 '%u' denotes id of the domain  << 
 77                                                << 
 78         offset=\fB%u\fP                        << 
 79                 '%u' offset within the PMT MMI << 
 80                                                << 
 81         lsb=\fB%u\fP                           << 
 82                 '%u' least significant bit wit << 
 83                                                << 
 84         msb=\fB%u\fP                           << 
 85                 '%u' most significant bit with << 
 86                                                << 
 87         guid=\fB%x\fP                          << 
 88                 '%x' hex identifier of the PMT << 
 89 .fi                                            << 
 90 .PP                                            << 
 91 \fB--cpu cpu-set\fP limit output to system sum     55 \fB--cpu cpu-set\fP limit output to system summary plus the specified cpu-set.  If cpu-set is the string "core", then the system summary plus the first CPU in each core are printed -- eg. subsequent HT siblings are not printed.  Or if cpu-set is the string "package", then the system summary plus the first CPU in each package is printed.  Otherwise, the system summary plus the specified set of CPUs are printed.  The cpu-set is ordered from low to high, comma delimited with ".." and "-" permitted to denote a range. eg. 1,2,8,14..17,21-44
 92 .PP                                                56 .PP
 93 \fB--hide column\fP do not show the specified  !!  57 \fB--hide column\fP do not show the specified columns.  May be invoked multiple times, or with a comma-separated list of column names.  Use "--hide sysfs" to hide the sysfs statistics columns as a group.
 94 .PP                                            << 
 95 \fB--enable column\fP show the specified built << 
 96 The column name "all" can be used to enable al << 
 97 .PP                                                58 .PP
 98 \fB--show column\fP show only the specified bu !!  59 \fB--show column\fP show only the specified columns.  May be invoked multiple times, or with a comma-separated list of column names.  Use "--show sysfs" to show the sysfs statistics columns as a group.
 99 .PP                                            << 
100 \fB--show CATEGORY --hide CATEGORY\fP  Show an << 
101 .PP                                                60 .PP
102 \fB--Dump\fP displays the raw counter values.      61 \fB--Dump\fP displays the raw counter values.
103 .PP                                                62 .PP
104 \fB--quiet\fP Do not decode and print the syst     63 \fB--quiet\fP Do not decode and print the system configuration header information.
105 .PP                                                64 .PP
106 \fB--no-msr\fP Disable all the uses of the MSR << 
107 .PP                                            << 
108 \fB--no-perf\fP Disable all the uses of the pe << 
109 .PP                                            << 
110 \fB--interval seconds\fP overrides the default     65 \fB--interval seconds\fP overrides the default 5.0 second measurement interval.
111 .PP                                                66 .PP
112 \fB--num_iterations num\fP number of the measu << 
113 .PP                                            << 
114 \fB--out output_file\fP turbostat output is wr     67 \fB--out output_file\fP turbostat output is written to the specified output_file.
115 The file is truncated if it already exists, an     68 The file is truncated if it already exists, and it is created if it does not exist.
116 .PP                                                69 .PP
117 \fB--help\fP displays usage for the most commo     70 \fB--help\fP displays usage for the most common parameters.
118 .PP                                                71 .PP
119 \fB--Joules\fP displays energy in Joules, rath     72 \fB--Joules\fP displays energy in Joules, rather than dividing Joules by time to print power in Watts.
120 .PP                                                73 .PP
121 \fB--list\fP display column header names avail     74 \fB--list\fP display column header names available for use by --show and --hide, then exit.
122 .PP                                                75 .PP
123 \fB--Summary\fP limits output to a 1-line Syst     76 \fB--Summary\fP limits output to a 1-line System Summary for each interval.
124 .PP                                                77 .PP
125 \fB--TCC temperature\fP sets the Thermal Contr     78 \fB--TCC temperature\fP sets the Thermal Control Circuit temperature for systems which do not export that value.  This is used for making sense of the Digital Thermal Sensor outputs, as they return degrees Celsius below the TCC activation temperature.
126 .PP                                                79 .PP
127 \fB--version\fP displays the version.              80 \fB--version\fP displays the version.
128 .PP                                                81 .PP
129 The \fBcommand\fP parameter forks \fBcommand\f     82 The \fBcommand\fP parameter forks \fBcommand\fP, and upon its exit,
130 displays the statistics gathered since it was      83 displays the statistics gathered since it was forked.
131 .PP                                                84 .PP
132 .SH ROW DESCRIPTIONS                               85 .SH ROW DESCRIPTIONS
133 The system configuration dump (if --quiet is n     86 The system configuration dump (if --quiet is not used) is followed by statistics.  The first row of the statistics labels the content of each column (below).  The second row of statistics is the system summary line.  The system summary line has a '-' in the columns for the Package, Core, and CPU.  The contents of the system summary line depends on the type of column.  Columns that count items (eg. IRQ) show the sum across all CPUs in the system.  Columns that show a percentage show the average across all CPUs in the system.  Columns that dump raw MSR values simply show 0 in the summary.  After the system summary row, each row describes a specific Package/Core/CPU.  Note that if the --cpu parameter is used to limit which specific CPUs are displayed, turbostat will still collect statistics for all CPUs in the system and will still show the system summary for all CPUs in the system.
134 .SH COLUMN DESCRIPTIONS                            87 .SH COLUMN DESCRIPTIONS
135 .PP                                            !!  88 .nf
136 \fBusec\fP For each CPU, the number of microse << 
137 .PP                                            << 
138 \fBTime_Of_Day_Seconds\fP For each CPU, the ge << 
139 .PP                                            << 
140 \fBCore\fP processor core number.  Note that m     89 \fBCore\fP processor core number.  Note that multiple CPUs per core indicate support for Intel(R) Hyper-Threading Technology (HT).
141 .PP                                            << 
142 \fBCPU\fP Linux CPU (logical processor) number     90 \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.
143 .PP                                            << 
144 \fBPackage\fP processor package number -- not      91 \fBPackage\fP processor package number -- not present on systems with a single processor package.
145 .PP                                            << 
146 \fBAvg_MHz\fP number of cycles executed divide     92 \fBAvg_MHz\fP number of cycles executed divided by time elapsed.  Note that this includes idle-time when 0 instructions are executed.
147 .PP                                            << 
148 \fBBusy%\fP percent of the measurement interva     93 \fBBusy%\fP percent of the measurement interval that the CPU executes instructions, aka. % of time in "C0" state.
149 .PP                                            << 
150 \fBBzy_MHz\fP average clock rate while the CPU     94 \fBBzy_MHz\fP average clock rate while the CPU was not idle (ie. in "c0" state).
151 .PP                                            << 
152 \fBTSC_MHz\fP average MHz that the TSC ran dur     95 \fBTSC_MHz\fP average MHz that the TSC ran during the entire interval.
153 .PP                                            << 
154 \fBIRQ\fP The number of interrupts serviced by     96 \fBIRQ\fP The number of interrupts serviced by that CPU during the measurement interval.  The system total line is the sum of interrupts serviced across all CPUs.  turbostat parses /proc/interrupts to generate this summary.
155 .PP                                            << 
156 \fBSMI\fP The number of System Management Inte     97 \fBSMI\fP The number of System Management Interrupts  serviced CPU during the measurement interval.  While this counter is actually per-CPU, SMI are triggered on all processors, so the number should be the same for all CPUs.
157 .PP                                            << 
158 \fBC1, C2, C3...\fP The number times Linux req     98 \fBC1, C2, C3...\fP The number times Linux requested the C1, C2, C3 idle state during the measurement interval.  The system summary line shows the sum for all CPUs.  These are C-state names as exported in /sys/devices/system/cpu/cpu*/cpuidle/state*/name.  While their names are generic, their attributes are processor specific. They the system description section of output shows what MWAIT sub-states they are mapped to on each system.
159 .PP                                            << 
160 \fBC1%, C2%, C3%\fP The residency percentage t     99 \fBC1%, C2%, C3%\fP The residency percentage that Linux requested C1, C2, C3....  The system summary is the average of all CPUs in the system.  Note that these are software, reflecting what was requested.  The hardware counters reflect what was actually achieved.
161 .PP                                            << 
162 \fBCPU%c1, CPU%c3, CPU%c6, CPU%c7\fP show the     100 \fBCPU%c1, CPU%c3, CPU%c6, CPU%c7\fP show the percentage residency in hardware core idle states.  These numbers are from hardware residency counters.
163 .PP                                            << 
164 \fBCoreTmp\fP Degrees Celsius reported by the     101 \fBCoreTmp\fP Degrees Celsius reported by the per-core Digital Thermal Sensor.
165 .PP                                            !! 102 \fBPkgTtmp\fP Degrees Celsius reported by the per-package Package Thermal Monitor.
166 \fBPkgTmp\fP Degrees Celsius reported by the p !! 103 \fBGFX%rc6\fP The percentage of time the GPU is in the "render C6" state, rc6, during the measurement interval. From /sys/class/drm/card0/power/rc6_residency_ms.
167 .PP                                            !! 104 \fBGFXMHz\fP Instantaneous snapshot of what sysfs presents at the end of the measurement interval. From /sys/class/graphics/fb0/device/drm/card0/gt_cur_freq_mhz.
168 \fBGFX%rc6\fP The percentage of time the GPU i << 
169 .PP                                            << 
170 \fBGFXMHz\fP Instantaneous snapshot of what sy << 
171 .PP                                            << 
172 \fBGFXAMHz\fP Instantaneous snapshot of what s << 
173 .PP                                            << 
174 \fBSAM%mc6\fP The percentage of time the SA Me << 
175 .PP                                            << 
176 \fBSAMMHz\fP Instantaneous snapshot of what sy << 
177 .PP                                            << 
178 \fBSAMAMHz\fP Instantaneous snapshot of what s << 
179 .PP                                            << 
180 \fBPkg%pc2, Pkg%pc3, Pkg%pc6, Pkg%pc7\fP perce    105 \fBPkg%pc2, Pkg%pc3, Pkg%pc6, Pkg%pc7\fP percentage residency in hardware package idle states.  These numbers are from hardware residency counters.
181 .PP                                            << 
182 \fBPkgWatt\fP Watts consumed by the whole pack    106 \fBPkgWatt\fP Watts consumed by the whole package.
183 .PP                                            << 
184 \fBCorWatt\fP Watts consumed by the core part     107 \fBCorWatt\fP Watts consumed by the core part of the package.
185 .PP                                            << 
186 \fBGFXWatt\fP Watts consumed by the Graphics p    108 \fBGFXWatt\fP Watts consumed by the Graphics part of the package -- available only on client processors.
187 .PP                                            << 
188 \fBRAMWatt\fP Watts consumed by the DRAM DIMMS    109 \fBRAMWatt\fP Watts consumed by the DRAM DIMMS -- available only on server processors.
189 .PP                                            !! 110 \fBPKG_%\fP percent of the interval that RAPL throttling was active on the Package.
190 \fBPKG_%\fP percent of the interval that RAPL  << 
191 .PP                                            << 
192 \fBRAM_%\fP percent of the interval that RAPL     111 \fBRAM_%\fP percent of the interval that RAPL throttling was active on DRAM.
193 .PP                                            !! 112 .fi
194 \fBUncMHz\fP per-package uncore MHz, instantan << 
195 .PP                                            << 
196 \fBUMHz1.0\fP per-package uncore MHz for domai << 
197 .SH TOO MUCH INFORMATION EXAMPLE                  113 .SH TOO MUCH INFORMATION EXAMPLE
198 By default, turbostat dumps all possible infor    114 By default, turbostat dumps all possible information -- a system configuration header, followed by columns for all counters.
199 This is ideal for remote debugging, use the "-    115 This is ideal for remote debugging, use the "--out" option to save everything to a text file, and get that file to the expert helping you debug.
200 .PP                                               116 .PP
201 When you are not interested in all that inform    117 When you are not interested in all that information, and there are several ways to see only what you want.  First the "--quiet" option will skip the configuration information, and turbostat will show only the counter columns.  Second, you can reduce the columns with the "--hide" and "--show" options.  If you use the "--show" option, then turbostat will show only the columns you list.  If you use the "--hide" option, turbostat will show all columns, except the ones you list.
202 .PP                                               118 .PP
203 To find out what columns are available for --s !! 119 To find out what columns are available for --show and --hide, the "--list" option is available.  For convenience, the special strings "sysfs" can be used to refer to all of the sysfs C-state counters at once:
204 .PP                                            << 
205 .nf                                               120 .nf
206 sudo ./turbostat --show sysfs --quiet sleep 10    121 sudo ./turbostat --show sysfs --quiet sleep 10
207 10.003837 sec                                     122 10.003837 sec
208         C1      C1E     C3      C6      C7s       123         C1      C1E     C3      C6      C7s     C1%     C1E%    C3%     C6%     C7s%
209         4       21      2       2       459       124         4       21      2       2       459     0.14    0.82    0.00    0.00    98.93
210         1       17      2       2       130       125         1       17      2       2       130     0.00    0.02    0.00    0.00    99.80
211         0       0       0       0       31        126         0       0       0       0       31      0.00    0.00    0.00    0.00    99.95
212         2       1       0       0       52        127         2       1       0       0       52      1.14    6.49    0.00    0.00    92.21
213         1       2       0       0       52        128         1       2       0       0       52      0.00    0.08    0.00    0.00    99.86
214         0       0       0       0       71        129         0       0       0       0       71      0.00    0.00    0.00    0.00    99.89
215         0       0       0       0       25        130         0       0       0       0       25      0.00    0.00    0.00    0.00    99.96
216         0       0       0       0       74        131         0       0       0       0       74      0.00    0.00    0.00    0.00    99.94
217         0       1       0       0       24        132         0       1       0       0       24      0.00    0.00    0.00    0.00    99.84
218 .fi                                               133 .fi
219 .PP                                               134 .PP
220 .SH ONE SHOT COMMAND EXAMPLE                      135 .SH ONE SHOT COMMAND EXAMPLE
221 If turbostat is invoked with a command, it wil    136 If turbostat is invoked with a command, it will fork that command
222 and output the statistics gathered after the c    137 and output the statistics gathered after the command exits.
223 In this case, turbostat output goes to stderr,    138 In this case, turbostat output goes to stderr, by default.
224 Output can instead be saved to a file using th    139 Output can instead be saved to a file using the --out option.
225 In this example, the "sleep 10" command is for    140 In this example, the "sleep 10" command is forked, and turbostat waits for it to complete before saving all statistics into "ts.out".  Note that "sleep 10" is not part of turbostat, but is simply an example of a command that turbostat can fork.  The "ts.out" file is what you want to edit in a very wide window, paste into a spreadsheet, or attach to a bugzilla entry.
226                                                   141 
227 .nf                                               142 .nf
228 [root@hsw]# ./turbostat -o ts.out sleep 10        143 [root@hsw]# ./turbostat -o ts.out sleep 10
229 [root@hsw]#                                       144 [root@hsw]#
230 .fi                                               145 .fi
231                                                   146 
232 .SH PERIODIC INTERVAL EXAMPLE                     147 .SH PERIODIC INTERVAL EXAMPLE
233 Without a command to fork, turbostat displays     148 Without a command to fork, turbostat displays statistics ever 5 seconds.
234 Periodic output goes to stdout, by default, un    149 Periodic output goes to stdout, by default, unless --out is used to specify an output file.
235 The 5-second interval can be changed with the     150 The 5-second interval can be changed with the "-i sec" option.
236 .nf                                               151 .nf
237 sudo turbostat --quiet --show CPU,frequency    !! 152 sudo ./turbostat --quiet --hide sysfs,IRQ,SMI,CoreTmp,PkgTmp,GFX%rc6,GFXMHz,PkgWatt,CorWatt,GFXWatt
238         Core    CPU     Avg_MHz Busy%   Bzy_MH !! 153         Core    CPU     Avg_MHz Busy%   Bzy_MHz TSC_MHz CPU%c1  CPU%c3  CPU%c6  CPU%c7
239         -       -       524     12.48   4198   !! 154         -       -       488     12.52   3900    3498    12.50   0.00    0.00    74.98
240         0       0       4       0.09    4081   !! 155         0       0       5       0.13    3900    3498    99.87   0.00    0.00    0.00
241         0       4       1       0.02    4063   !! 156         0       4       3897    99.99   3900    3498    0.01
242         1       1       2       0.06    4063   !! 157         1       1       0       0.00    3856    3498    0.01    0.00    0.00    99.98
243         1       5       2       0.05    4070   !! 158         1       5       0       0.00    3861    3498    0.01
244         2       2       4178    99.52   4199   !! 159         2       2       1       0.02    3889    3498    0.03    0.00    0.00    99.95
245         2       6       3       0.08    4159   !! 160         2       6       0       0.00    3863    3498    0.05
246         3       3       1       0.04    4046   !! 161         3       3       0       0.01    3869    3498    0.02    0.00    0.00    99.97
247         3       7       0       0.01    3989   !! 162         3       7       0       0.00    3878    3498    0.03
248         Core    CPU     Avg_MHz Busy%   Bzy_MH !! 163         Core    CPU     Avg_MHz Busy%   Bzy_MHz TSC_MHz CPU%c1  CPU%c3  CPU%c6  CPU%c7
249         -       -       525     12.52   4198   !! 164         -       -       491     12.59   3900    3498    12.42   0.00    0.00    74.99
250         0       0       4       0.10    4051   !! 165         0       0       27      0.69    3900    3498    99.31   0.00    0.00    0.00
251         0       4       2       0.04    3993   !! 166         0       4       3898    99.99   3900    3498    0.01
252         1       1       3       0.07    4054   !! 167         1       1       0       0.00    3883    3498    0.01    0.00    0.00    99.99
253         1       5       4       0.10    4018   !! 168         1       5       0       0.00    3898    3498    0.01
254         2       2       4178    99.51   4199   !! 169         2       2       0       0.01    3889    3498    0.02    0.00    0.00    99.98
255         2       6       4       0.09    4143   !! 170         2       6       0       0.00    3889    3498    0.02
256         3       3       2       0.06    4026   !! 171         3       3       0       0.00    3856    3498    0.01    0.00    0.00    99.99
257         3       7       7       0.17    4074   !! 172         3       7       0       0.00    3897    3498    0.01
258 .fi                                               173 .fi
259 This example also shows the use of the --show  !! 174 This example also shows the use of the --hide option to skip columns that are not wanted.
                                                   >> 175 Note that cpu4 in this example is 99.99% busy, while the other CPUs are all under 1% busy.
                                                   >> 176 Notice that cpu4's HT sibling is cpu0, which is under 1% busy, but can get into CPU%c1 only,
                                                   >> 177 because its cpu4's activity on shared hardware keeps it from entering a deeper C-state.
260                                                   178 
261 .SH SYSTEM CONFIGURATION INFORMATION EXAMPLE      179 .SH SYSTEM CONFIGURATION INFORMATION EXAMPLE
262                                                   180 
263 By default, turbostat always dumps system conf    181 By default, turbostat always dumps system configuration information
264 before taking measurements.  In the example ab    182 before taking measurements.  In the example above, "--quiet" is used
265 to suppress that output.  Here is an example o    183 to suppress that output.  Here is an example of the configuration information:
266 .nf                                               184 .nf
267 turbostat version 2022.04.16 - Len Brown <lenb@ !! 185 turbostat version 2017.02.15 - Len Brown <lenb@kernel.org>
268 Kernel command line: BOOT_IMAGE=/boot/vmlinuz- !! 186 CPUID(0): GenuineIntel 13 CPUID levels; family:model:stepping 0x6:3c:3 (6:60:3)
269 CPUID(0): GenuineIntel 0x16 CPUID levels       !! 187 CPUID(1): SSE3 MONITOR - EIST TM2 TSC MSR ACPI-TM TM
270 CPUID(1): family:model:stepping 0x6:9e:9 (6:15 !! 188 CPUID(6): APERF, TURBO, DTS, PTM, No-HWP, No-HWPnotify, No-HWPwindow, No-HWPepp, No-HWPpkg, EPB
271 CPUID(0x80000000): max_extended_levels: 0x8000 !! 189 cpu4: MSR_IA32_MISC_ENABLE: 0x00850089 (TCC EIST No-MWAIT PREFETCH TURBO)
272 CPUID(1): SSE3 MONITOR - EIST TM2 TSC MSR ACPI !! 190 CPUID(7): No-SGX
273 CPUID(6): APERF, TURBO, DTS, PTM, HWP, HWPnoti !! 191 cpu4: MSR_MISC_PWR_MGMT: 0x00400000 (ENable-EIST_Coordination DISable-EPB DISable-OOB)
274 cpu7: MSR_IA32_MISC_ENABLE: 0x00850089 (TCC EI !! 192 RAPL: 3121 sec. Joule Counter Range, at 84 Watts
275 CPUID(7): SGX                                  !! 193 cpu4: MSR_PLATFORM_INFO: 0x80838f3012300
276 cpu7: MSR_IA32_FEATURE_CONTROL: 0x00000005 (Lo << 
277 CPUID(0x15): eax_crystal: 2 ebx_tsc: 258 ecx_c << 
278 TSC: 3096 MHz (24000000 Hz * 258 / 2 / 1000000 << 
279 CPUID(0x16): base_mhz: 3100 max_mhz: 4200 bus_ << 
280 cpu7: MSR_MISC_PWR_MGMT: 0x00401cc0 (ENable-EI << 
281 RAPL: 5825 sec. Joule Counter Range, at 45 Wat << 
282 cpu7: MSR_PLATFORM_INFO: 0x80839f1011f00       << 
283 8 * 100.0 = 800.0 MHz max efficiency frequency    194 8 * 100.0 = 800.0 MHz max efficiency frequency
284 31 * 100.0 = 3100.0 MHz base frequency         !! 195 35 * 100.0 = 3500.0 MHz base frequency
285 cpu7: MSR_IA32_POWER_CTL: 0x002c005d (C1E auto !! 196 cpu4: MSR_IA32_POWER_CTL: 0x0004005d (C1E auto-promotion: DISabled)
286 cpu7: MSR_TURBO_RATIO_LIMIT: 0x2728292a        !! 197 cpu4: MSR_TURBO_RATIO_LIMIT: 0x25262727
287 39 * 100.0 = 3900.0 MHz max turbo 4 active cor !! 198 37 * 100.0 = 3700.0 MHz max turbo 4 active cores
288 40 * 100.0 = 4000.0 MHz max turbo 3 active cor !! 199 38 * 100.0 = 3800.0 MHz max turbo 3 active cores
289 41 * 100.0 = 4100.0 MHz max turbo 2 active cor !! 200 39 * 100.0 = 3900.0 MHz max turbo 2 active cores
290 42 * 100.0 = 4200.0 MHz max turbo 1 active cor !! 201 39 * 100.0 = 3900.0 MHz max turbo 1 active cores
291 cpu7: MSR_CONFIG_TDP_NOMINAL: 0x0000001f (base !! 202 cpu4: MSR_CONFIG_TDP_NOMINAL: 0x00000023 (base_ratio=35)
292 cpu7: MSR_CONFIG_TDP_LEVEL_1: 0x00000000 ()    !! 203 cpu4: MSR_CONFIG_TDP_LEVEL_1: 0x00000000 ()
293 cpu7: MSR_CONFIG_TDP_LEVEL_2: 0x00000000 ()    !! 204 cpu4: MSR_CONFIG_TDP_LEVEL_2: 0x00000000 ()
294 cpu7: MSR_CONFIG_TDP_CONTROL: 0x80000000 ( loc !! 205 cpu4: MSR_CONFIG_TDP_CONTROL: 0x80000000 ( lock=1)
295 cpu7: MSR_TURBO_ACTIVATION_RATIO: 0x00000000 ( !! 206 cpu4: MSR_TURBO_ACTIVATION_RATIO: 0x00000000 (MAX_NON_TURBO_RATIO=0 lock=0)
296 cpu7: MSR_PKG_CST_CONFIG_CONTROL: 0x1e008008 ( !! 207 cpu4: MSR_PKG_CST_CONFIG_CONTROL: 0x1e000400 (UNdemote-C3, UNdemote-C1, demote-C3, demote-C1, UNlocked: pkg-cstate-limit=0: pc0)
297 Uncore Frequency pkg0 die0: 800 - 3900 MHz (80 !! 208 cpu4: POLL: CPUIDLE CORE POLL IDLE
298 /dev/cpu_dma_latency: 2000000000 usec (default !! 209 cpu4: C1: MWAIT 0x00
299 current_driver: intel_idle                     !! 210 cpu4: C1E: MWAIT 0x01
300 current_governor: menu                         !! 211 cpu4: C3: MWAIT 0x10
301 current_governor_ro: menu                      !! 212 cpu4: C6: MWAIT 0x20
302 cpu7: POLL: CPUIDLE CORE POLL IDLE             !! 213 cpu4: C7s: MWAIT 0x32
303 cpu7: C1: MWAIT 0x00                           !! 214 cpu4: MSR_MISC_FEATURE_CONTROL: 0x00000000 (L2-Prefetch L2-Prefetch-pair L1-Prefetch L1-IP-Prefetch)
304 cpu7: C1E: MWAIT 0x01                          !! 215 cpu0: MSR_IA32_ENERGY_PERF_BIAS: 0x00000006 (balanced)
305 cpu7: C3: MWAIT 0x10                           !! 216 cpu0: MSR_CORE_PERF_LIMIT_REASONS, 0x31200000 (Active: ) (Logged: Transitions, MultiCoreTurbo, Amps, Auto-HWP, )
306 cpu7: C6: MWAIT 0x20                           !! 217 cpu0: MSR_GFX_PERF_LIMIT_REASONS, 0x00000000 (Active: ) (Logged: )
307 cpu7: C7s: MWAIT 0x33                          !! 218 cpu0: MSR_RING_PERF_LIMIT_REASONS, 0x0d000000 (Active: ) (Logged: Amps, PkgPwrL1, PkgPwrL2, )
308 cpu7: C8: MWAIT 0x40                           << 
309 cpu7: C9: MWAIT 0x50                           << 
310 cpu7: C10: MWAIT 0x60                          << 
311 cpu7: cpufreq driver: intel_pstate             << 
312 cpu7: cpufreq governor: performance            << 
313 cpufreq intel_pstate no_turbo: 0               << 
314 cpu7: MSR_MISC_FEATURE_CONTROL: 0x00000000 (L2 << 
315 cpu0: MSR_PM_ENABLE: 0x00000001 (HWP)          << 
316 cpu0: MSR_HWP_CAPABILITIES: 0x01101f53 (high 8 << 
317 cpu0: MSR_HWP_REQUEST: 0x00005353 (min 83 max  << 
318 cpu0: MSR_HWP_INTERRUPT: 0x00000001 (EN_Guaran << 
319 cpu0: MSR_HWP_STATUS: 0x00000004 (No-Guarantee << 
320 cpu0: EPB: 6 (balanced)                        << 
321 cpu0: MSR_RAPL_POWER_UNIT: 0x000a0e03 (0.12500    219 cpu0: MSR_RAPL_POWER_UNIT: 0x000a0e03 (0.125000 Watts, 0.000061 Joules, 0.000977 sec.)
322 cpu0: MSR_PKG_POWER_INFO: 0x00000168 (45 W TDP !! 220 cpu0: MSR_PKG_POWER_INFO: 0x000002a0 (84 W TDP, RAPL 0 - 0 W, 0.000000 sec.)
323 cpu0: MSR_PKG_POWER_LIMIT: 0x42820800218208 (U !! 221 cpu0: MSR_PKG_POWER_LIMIT: 0x428348001a82a0 (UNlocked)
324 cpu0: PKG Limit #1: ENabled (65.000 Watts, 64. !! 222 cpu0: PKG Limit #1: ENabled (84.000000 Watts, 8.000000 sec, clamp DISabled)
325 cpu0: PKG Limit #2: ENabled (65.000 Watts, 0.0 !! 223 cpu0: PKG Limit #2: ENabled (105.000000 Watts, 0.002441* sec, clamp DISabled)
326 cpu0: MSR_VR_CURRENT_CONFIG: 0x00000000        << 
327 cpu0: PKG Limit #4: 0.000000 Watts (UNlocked)  << 
328 cpu0: MSR_DRAM_POWER_LIMIT: 0x5400de00000000 ( << 
329 cpu0: DRAM Limit: DISabled (0.000 Watts, 0.000 << 
330 cpu0: MSR_PP0_POLICY: 0                           224 cpu0: MSR_PP0_POLICY: 0
331 cpu0: MSR_PP0_POWER_LIMIT: 0x00000000 (UNlocke    225 cpu0: MSR_PP0_POWER_LIMIT: 0x00000000 (UNlocked)
332 cpu0: Cores Limit: DISabled (0.000 Watts, 0.00 !! 226 cpu0: Cores Limit: DISabled (0.000000 Watts, 0.000977 sec, clamp DISabled)
333 cpu0: MSR_PP1_POLICY: 0                           227 cpu0: MSR_PP1_POLICY: 0
334 cpu0: MSR_PP1_POWER_LIMIT: 0x00000000 (UNlocke    228 cpu0: MSR_PP1_POWER_LIMIT: 0x00000000 (UNlocked)
335 cpu0: GFX Limit: DISabled (0.000 Watts, 0.0009 !! 229 cpu0: GFX Limit: DISabled (0.000000 Watts, 0.000977 sec, clamp DISabled)
336 cpu0: MSR_IA32_TEMPERATURE_TARGET: 0x00640000  !! 230 cpu0: MSR_IA32_TEMPERATURE_TARGET: 0x00641400 (100 C)
337 cpu0: MSR_IA32_PACKAGE_THERM_STATUS: 0x8820080 !! 231 cpu0: MSR_IA32_PACKAGE_THERM_STATUS: 0x884c0800 (24 C)
338 cpu0: MSR_IA32_PACKAGE_THERM_INTERRUPT: 0x0000 !! 232 cpu0: MSR_IA32_THERM_STATUS: 0x884c0000 (24 C +/- 1)
339 cpu7: MSR_PKGC3_IRTL: 0x0000884e (valid, 79872 !! 233 cpu1: MSR_IA32_THERM_STATUS: 0x88510000 (19 C +/- 1)
340 cpu7: MSR_PKGC6_IRTL: 0x00008876 (valid, 12083 !! 234 cpu2: MSR_IA32_THERM_STATUS: 0x884e0000 (22 C +/- 1)
341 cpu7: MSR_PKGC7_IRTL: 0x00008894 (valid, 15155 !! 235 cpu3: MSR_IA32_THERM_STATUS: 0x88510000 (19 C +/- 1)
342 cpu7: MSR_PKGC8_IRTL: 0x000088fa (valid, 25600 !! 236 cpu4: MSR_PKGC3_IRTL: 0x00008842 (valid, 67584 ns)
343 cpu7: MSR_PKGC9_IRTL: 0x0000894c (valid, 33996 !! 237 cpu4: MSR_PKGC6_IRTL: 0x00008873 (valid, 117760 ns)
344 cpu7: MSR_PKGC10_IRTL: 0x00008bf2 (valid, 1034 !! 238 cpu4: MSR_PKGC7_IRTL: 0x00008891 (valid, 148480 ns)
345 .fi                                               239 .fi
346 .PP                                            << 
347 The \fBmax efficiency\fP frequency, a.k.a. Low    240 The \fBmax efficiency\fP frequency, a.k.a. Low Frequency Mode, is the frequency
348 available at the minimum package voltage.  The    241 available at the minimum package voltage.  The \fBTSC frequency\fP is the base
349 frequency of the processor -- this should matc    242 frequency of the processor -- this should match the brand string
350 in /proc/cpuinfo.  This base frequency            243 in /proc/cpuinfo.  This base frequency
351 should be sustainable on all CPUs indefinitely    244 should be sustainable on all CPUs indefinitely, given nominal power and cooling.
352 The remaining rows show what maximum turbo fre    245 The remaining rows show what maximum turbo frequency is possible
353 depending on the number of idle cores.  Note t    246 depending on the number of idle cores.  Note that not all information is
354 available on all processors.                      247 available on all processors.
355 .SH ADD COUNTER EXAMPLE                           248 .SH ADD COUNTER EXAMPLE
356 Here we limit turbostat to showing just the CP    249 Here we limit turbostat to showing just the CPU number for cpu0 - cpu3.
357 We add a counter showing the 32-bit raw value     250 We add a counter showing the 32-bit raw value of MSR 0x199 (MSR_IA32_PERF_CTL),
358 labeling it with the column header, "PRF_CTRL"    251 labeling it with the column header, "PRF_CTRL", and display it only once,
359 after the conclusion of a 0.1 second sleep.    !! 252 afte the conclusion of a 0.1 second sleep.
360 .nf                                               253 .nf
361 sudo ./turbostat --quiet --cpu 0-3 --show CPU     254 sudo ./turbostat --quiet --cpu 0-3 --show CPU --add msr0x199,u32,raw,PRF_CTRL sleep .1
362 0.101604 sec                                      255 0.101604 sec
363 CPU       PRF_CTRL                                256 CPU       PRF_CTRL
364 -       0x00000000                                257 -       0x00000000
365 0       0x00000c00                                258 0       0x00000c00
366 1       0x00000800                                259 1       0x00000800
367 2       0x00000a00                                260 2       0x00000a00
368 3       0x00000800                                261 3       0x00000800
369                                                   262 
370 .fi                                               263 .fi
371                                                   264 
372 .SH ADD PERF COUNTER EXAMPLE                   << 
373 Here we limit turbostat to showing just the CP << 
374 We add a counter showing time spent in C1 core << 
375 labeling it with the column header, "pCPU%c1", << 
376 after the conclusion of 0.1 second sleep.      << 
377 We also show CPU%c1 built-in counter that shou << 
378 .nf                                            << 
379 sudo ./turbostat --quiet --cpu 0-3 --show CPU, << 
380 0.102448 sec                                   << 
381 CPU     pCPU%c1 CPU%c1                         << 
382 -       34.89   34.89                          << 
383 0       45.99   45.99                          << 
384 1       45.94   45.94                          << 
385 2       23.83   23.83                          << 
386 3       23.84   23.84                          << 
387                                                << 
388 .fi                                            << 
389                                                << 
390 .SH ADD PMT COUNTER EXAMPLE                    << 
391 Here we limit turbostat to showing just the CP << 
392 We add two counters, showing crystal clock cou << 
393 All the parameters passed are based on the met << 
394                                                << 
395 For the crystal clock count, we                << 
396 label it with the column header, "XTAL",       << 
397 we set the type to 'raw', to read the number o << 
398 we set the format to 'delta', to display the d << 
399 we set the domain to 'package0', to collect it << 
400 we set the offset to '0', which is a offset of << 
401 we set the lsb and msb to cover all 64 bits of << 
402 and finally we set the guid to '0x1a067102', t << 
403                                                << 
404 For the DC6 residency counter, we              << 
405 label it with the column header, "Die%c6",     << 
406 we set the type to 'txtal_time', to obtain the << 
407 we set the format to 'delta', to display the d << 
408 we set the domain to 'package0', to collect it << 
409 we set the offset to '0', which is a offset of << 
410 we set the lsb and msb to cover all 64 bits of << 
411 and finally we set the guid to '0x1a067102', t << 
412                                                << 
413 .nf                                            << 
414 sudo ./turbostat --quiet --cpu 0 --show CPU -- << 
415 0.104352 sec                                   << 
416 CPU                   XTAL      Die%c6         << 
417 -       0x0000006d4d957ca7      0.00           << 
418 0       0x0000006d4d957ca7      0.00           << 
419 0.102448 sec                                   << 
420 .fi                                            << 
421                                                << 
422 .SH INPUT                                      << 
423                                                << 
424 For interval-mode, turbostat will immediately  << 
425 when it sees a newline on standard input.      << 
426 turbostat will then start the next interval.   << 
427 Control-C will be send a SIGINT to turbostat,  << 
428 which will immediately abort the program with  << 
429 .SH SIGNALS                                    << 
430                                                << 
431 SIGINT will interrupt interval-mode.           << 
432 The end-of-interval data will be collected and << 
433                                                << 
434 SIGUSR1 will end current interval,             << 
435 end-of-interval data will be collected and dis << 
436 starts a new interval.                         << 
437 .SH NOTES                                         265 .SH NOTES
438                                                   266 
439 .B "turbostat "                                   267 .B "turbostat "
440 must be run as root.                              268 must be run as root.
441 Alternatively, non-root users can be enabled t    269 Alternatively, non-root users can be enabled to run turbostat this way:
442                                                   270 
443 # setcap cap_sys_admin,cap_sys_rawio,cap_sys_n !! 271 # setcap cap_sys_rawio=ep ./turbostat
444                                                   272 
445 # chmod +r /dev/cpu/*/msr                         273 # chmod +r /dev/cpu/*/msr
446                                                   274 
447 # chmod +r /dev/cpu_dma_latency                << 
448                                                << 
449 .B "turbostat "                                   275 .B "turbostat "
450 reads hardware counters, but doesn't write the    276 reads hardware counters, but doesn't write them.
451 So it will not interfere with the OS or other     277 So it will not interfere with the OS or other programs, including
452 multiple invocations of itself.                   278 multiple invocations of itself.
453                                                   279 
454 \fBturbostat \fP                                  280 \fBturbostat \fP
455 may work poorly on Linux-2.6.20 through 2.6.29    281 may work poorly on Linux-2.6.20 through 2.6.29,
456 as \fBacpi-cpufreq \fPperiodically cleared the    282 as \fBacpi-cpufreq \fPperiodically cleared the APERF and MPERF MSRs
457 in those kernels.                                 283 in those kernels.
458                                                   284 
459 AVG_MHz = APERF_delta/measurement_interval.  T    285 AVG_MHz = APERF_delta/measurement_interval.  This is the actual
460 number of elapsed cycles divided by the entire    286 number of elapsed cycles divided by the entire sample interval --
461 including idle time.  Note that this calculati    287 including idle time.  Note that this calculation is resilient
462 to systems lacking a non-stop TSC.                288 to systems lacking a non-stop TSC.
463                                                   289 
464 TSC_MHz = TSC_delta/measurement_interval.         290 TSC_MHz = TSC_delta/measurement_interval.
465 On a system with an invariant TSC, this value     291 On a system with an invariant TSC, this value will be constant
466 and will closely match the base frequency valu    292 and will closely match the base frequency value shown
467 in the brand string in /proc/cpuinfo.  On a sy    293 in the brand string in /proc/cpuinfo.  On a system where
468 the TSC stops in idle, TSC_MHz will drop          294 the TSC stops in idle, TSC_MHz will drop
469 below the processor's base frequency.             295 below the processor's base frequency.
470                                                   296 
471 Busy% = MPERF_delta/TSC_delta                     297 Busy% = MPERF_delta/TSC_delta
472                                                   298 
473 Bzy_MHz = TSC_delta*APERF_delta/MPERF_delta/me !! 299 Bzy_MHz = TSC_delta/APERF_delta/MPERF_delta/measurement_interval
474                                                   300 
475 Note that these calculations depend on TSC_del    301 Note that these calculations depend on TSC_delta, so they
476 are not reliable during intervals when TSC_MHz    302 are not reliable during intervals when TSC_MHz is not running at the base frequency.
477                                                   303 
478 Turbostat data collection is not atomic.          304 Turbostat data collection is not atomic.
479 Extremely short measurement intervals (much le    305 Extremely short measurement intervals (much less than 1 second),
480 or system activity that prevents turbostat fro    306 or system activity that prevents turbostat from being able
481 to run on all CPUS to quickly collect data, wi    307 to run on all CPUS to quickly collect data, will result in
482 inconsistent results.                             308 inconsistent results.
483                                                   309 
484 The APERF, MPERF MSRs are defined to count non    310 The APERF, MPERF MSRs are defined to count non-halted cycles.
485 Although it is not guaranteed by the architect    311 Although it is not guaranteed by the architecture, turbostat assumes
486 that they count at TSC rate, which is true on     312 that they count at TSC rate, which is true on all processors tested to date.
487                                                   313 
488 .SH REFERENCES                                    314 .SH REFERENCES
489 Volume 3B: System Programming Guide"              315 Volume 3B: System Programming Guide"
490 https://www.intel.com/products/processor/manua !! 316 http://www.intel.com/products/processor/manuals/
491                                                   317 
492 .SH FILES                                         318 .SH FILES
493 .ta                                               319 .ta
494 .nf                                               320 .nf
495 /dev/cpu/*/msr                                    321 /dev/cpu/*/msr
496 .fi                                               322 .fi
497                                                   323 
498 .SH "SEE ALSO"                                    324 .SH "SEE ALSO"
499 msr(4), vmstat(8)                                 325 msr(4), vmstat(8)
500 .PP                                               326 .PP
501 .SH AUTHOR                                        327 .SH AUTHOR
502 .nf                                               328 .nf
503 Written by Len Brown <len.brown@intel.com>         329 Written by Len Brown <len.brown@intel.com>
                                                      

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php