PEPC-PSTATES(1)
π PEPC-PSTATES(1) β the pstates glow-up π
okay bestie, welcome to PEPC-PSTATES(1), a General Commands Manual moment. this is the page for the command pstates and she is that girl. buckle up, we're going module by module. π¦
β¨ Command 'pstates' β¨
πΈ General options πΈ
these are the ones that apply no matter what you're doing. the little black dresses of flags. π
-hβ shows you a short help message and then dips. bye! π-qβ be quiet mode. only important messages get through (think: warnings). lowkey a vibe. π€«-dβ print debugging information. yes, all of it. it's giving loud. π£οΈ--debug-modules MODNAME[,MODNAME1,...]β so-dturns on every debug message ever, which is a lot. this option narrows it down to just the modules you name. like,-d --debug-modules MSRwill only show debug messages from theMSRmodule. slay, targeted. π―--versionβ prints the version number and exits. periodt. β-H HOSTNAME,--host HOSTNAMEβ host name or IP address of the target system. thepepccommand gets executed over on that system using SSH instead of running locally. if you don't specify it, the command just runs locally. homebody behavior, honestly. π-U USERNAME,--username USERNAMEβ the name of the user you're logging into the remote host as, over SSH. by default it looks the user name up in SSH configuration files, and if it's not there, it uses the current user name. β¨-K PRIVKEY,--priv-key PRIVKEYβ path to the private SSH key for logging into the remote host. if you don't specify one, the keys configured for the host in SSH configuration files (e.g.~/.ssh/config) get used. if nothing's configured there, standard key files (e.g.~/.ssh/id_rsa) and the SSH agent get tried. the full backup plan energy. π-D DATASET,--dataset DATASETβ for debugging and testing. it specifies the dataset to use for emulating the host that the command runs on. the datasets live in thepepcsource code repository.
the argument can be a dataset path or a name. if you give a name, these locations get searched, in this order:
./tests/emul-datain the program's directory$PEPC_DATA_PATH/tests/emul-data$VIRTUAL_ENV/share/pepc/tests/emul-data$HOME/.local/share/pepc/tests/emul-data/usr/local/share/pepc/tests/emul-data/usr/share/pepc/tests/emul-data
--force-colorβ forces colorized output even when the output stream isn't a terminal. yes, it adds ANSI escape codes. rainbow whether you asked or not π--print-man-pathβ prints thepepcmanual pages directory path and exits. add this path to theMANPATHenvironment variable so the manual pages become available to themantool. very helpful of her. π«Ά--override-cpu-model VFMβ for debugging and testing only. overrides the target host CPU model and forcespepcto treat the host as a specific CPU model. the format is[<Vendor>:][<Family>:]<Model>, where<Vendor>is the CPU vendor (e.g.,GenuineIntelorAuthenticAMD),<Family>is the CPU family (e.g.,6), and<Model>is the CPU model (e.g.,0x8F). example:GenuineIntel:6:0x8Ftreats the target as a Sapphire Rapids Xeon. vendor and family are optional β if you omit them, the target host values get used. family and model can be written in decimal or hexadecimal. π§
π Target CPU specification options π
all the subcommands (info, config) support these target CPU specification options. it's giving "pick your fighter". π
--cpus CPUSβ the list can include individual CPU numbers and CPU number ranges. for example,1-4,7,8,10-12would mean CPUs 1 to 4, CPUs 7, 8, and 10 to 12. use the special keywordallto specify all CPUs. π--cores CORESβ the list can include individual core numbers and core number ranges. for example,1-4,7,8,10-12would mean cores 1 to 4, cores 7, 8, and 10 to 12. use the special keywordallto specify all cores. core numbers are relative to the package. π--modules MODULESβ the list can include individual module numbers and module number ranges. for example,0,2-5would mean module 0 and modules 2, 3, 4, and 5. use the special keywordallto specify all modules. heads up: unlike core and die numbers, module numbers are absolute. π₯--dies DIESβ the list can include individual die numbers and die number ranges. for example,0-3,5would mean dies 0 to 3, and die 5. use the special keywordallto specify all dies. on some systems, die numbers are globally unique, while on other systems they're relative to the package. it depends, bestie. π€·--packages PACKAGESβ the list can include individual package numbers and package number ranges. for example,0,2-4would mean package 0 and packages 2 to 4. use the special keywordallto specify all packages. π--core-siblingsCORE_SIBLINGS β core siblings are CPUs sharing the same core. the list can include individual core sibling indices or index ranges. for example, if a core includes CPUs 3 and 4, index 0 would mean CPU 3 and index 1 would mean CPU 4. this option can only be used to reference online CPUs, because Linux does not provide topology information for offline CPUs. in the example with CPUs 3 and 4, if CPU 3 was offline, then index 0 would mean CPU 4. π--module-siblingsMODULE_SIBLINGS β module siblings are CPUs sharing the same module. the list can include individual module sibling indices or index ranges. for example, if a module includes CPUs 3, 4, 5, and 6, index 0 would mean CPU 3, index 1 would mean CPU 4, index 2 would mean CPU 5, and index 3 would mean CPU 6. this option can only be used to reference online CPUs, because Linux does not provide topology information for offline CPUs. in the example with CPUs 3, 4, 5, and 6, if CPU 4 was offline, then index 1 would mean CPU 5, index 2 would mean CPU 6, and index 3 would be invalid. π
π¦ Subcommand 'info' π¦
retrieves CPU P-states information for the CPUs you specify. by default it displays all details for all CPUs. use the target CPU specification options above to define a subset of CPUs, cores, dies, or packages. the way that this subcommand just hands you the whole pictureβ¦ obsessed. π
-m MECHANISMS,--mechanisms MECHANISMSβ a comma-separated list of mechanisms for retrieving information. use--list-mechanismsto view the available ones. many options support only one mechanism (e.g.,sysfs), while others may support multiple (e.g.,sysfsandmsr). mechanisms get tried in the order you specified. by default, all mechanisms are allowed, and the most preferred ones are tried first. β¨--list-mechanismsβ displays the available mechanisms for retrieving CPU P-states information. π--min-freqβ retrieves the minimum CPU frequency from/sys/devices/system/cpu/cpu<N>/cpufreq/scaling_min_freq.--max-freqβ retrieves the maximum CPU frequency from/sys/devices/system/cpu/cpu<N>/cpufreq/scaling_max_freq.--min-freq-limitβ retrieves the minimum supported CPU frequency from/sys/devices/system/cpu/cpu<N>/cpufreq/cpuinfo_min_freq.--max-freq-limitβ retrieves the maximum supported CPU frequency from/sys/devices/system/cpu/cpu<N>/cpufreq/cpuinfo_max_freq.--hwpβ checks if hardware power management is enabled. when it's enabled, CPUs can scale their frequency automatically without OS involvement. mechanism:msr, readsMSR_PM_ENABLE(0x770), bit 0. this setting has global scope. π--frequenciesβ lists the CPU frequencies supported by the Linux kernel for the--min-freqand--max-freqoptions. if/sys/devices/system/cpu/cpufreq/policy<N>/scaling_available_frequenciesis available (usually the case with theacpi_cpufreqdriver), it retrieves the data from there. otherwise, in the case of an Intel platform, it assumes that all frequencies from--min-freq-limitto--max-freq-limitare available with a step equal to--bus-clock. πΆ--base-freqβ retrieves the base CPU frequency from/sys/devices/system/cpu/cpu<N>/cpufreq/base_frequency. if that file is unavailable, it falls back to/sys/devices/system/cpu/cpu<N>/cpufreq/bios_limit. π--fixed-base-freqβ retrieves the CPU fixed base frequency fromMSR_PLATFORM_INFO(0xCE), bits 15:8.--bus-clockβ retrieves the bus clock frequency, one of the CPU's reference clocks. themsrmechanism readsMSR_FSB_FREQ(0xCD), bits 2:0, for legacy Intel platforms. for modern Intel platforms, thedocmechanism assumes a100MHzbus clock. β°--turboβ checks if turbo is enabled or disabled. when it's enabled, CPUs can run at frequencies above the base frequency if the OS and thermal conditions allow it. it reads the sysfs file based on the CPU frequency driver: intel_pstate β/sys/devices/system/cpu/intel_pstate/no_turbo, acpi-cpufreq β/sys/devices/system/cpu/cpufreq/boost. the setting has global scope. π--eppβ retrieves EPP (Energy Performance Preference) usingsysfs(preferred) ormsrmechanisms. EPP is a hint to the CPU on energy efficiency versus performance. on Intel CPUs, bothmsrandsysfsmechanisms are supported, with values ranging from0-255(maximum energy efficiency to maximum performance) or policy names (sysfsmechanism only). on AMD CPUs, onlysysfsis supported, with policy names only. thesysfsmechanism reads/sys/devices/system/cpu/cpufreq/policy<N>/energy_performance_preference, while themsrmechanism readsMSR_HWP_REQUEST(0x774), bits 31:24. π±--epbβ retrieves EPB (Energy Performance Bias) usingsysfs(preferred) ormsrmechanisms. EPB is a hint to the CPU on energy efficiency versus performance. the value ranges from0-15(maximum performance to maximum energy efficiency) or can be a policy name (supported bysysfsonly). thesysfsmechanism reads/sys/devices/system/cpu/cpu<N>/power/energy_perf_bias, while themsrmechanism readsMSR_ENERGY_PERF_BIAS(0x1B0), bits 3:0. π--driverβ retrieves the CPU frequency driver name. the driver enumerates and manages CPU P-states on the platform. the name is read from/sys/devices/system/cpu/cpufreq/policy<N>/scaling_driver. while sysfs provides a per-CPU API, Intel platforms typically use a single driver. π--intel-pstate-modeβ retrieves theintelpstatedriver mode:active,passive, oroff. inactivemode, customintelpstategovernors are used. inpassivemode, generic Linux governors are employed. the mode is read from/sys/devices/system/cpu/intel_pstate/status. ποΈ
okay that's part 1 bestie, don't go anywhere, there's more coming π
--governorβ pulls the CPU frequency governor for you π and yes, the governor is literally the thing that picks the P-state based on CPU load and other factors. Reads the name straight outta/sys/devices/system/cpu/cpufreq/policy<N>/scaling_governor.--governorsβ shows you the whole menu of available CPU frequency governors. Every governor decides a CPU's P-state from its activity and other factors, and each one runs its own little selection policy like it's the main character. The lineup lives in/sys/devices/system/cpu/cpufreq/policy<N>/scaling_available_governors.--cppc-lowest-perfβ grabs the ACPI CPPC lowest performance level value for the CPUs you asked for, from/sys/devices/system/cpu/cpu<N>/acpi_cppc/lowest_perf.--cppc-lowest-nonlinear-perfβ same energy, different stat: the ACPI CPPC lowest nonlinear performance level value for specified CPUs, from/sys/devices/system/cpu/cpu<N>/acpi_cppc/lowest_nonlinear_perf.--cppc-guaranteed-perfβ yanks the ACPI CPPC guaranteed performance level value for specified CPUs out of/sys/devices/system/cpu/cpu<N>/acpi_cppc/guaranteed_perf.--cppc-nominal-perfβ the ACPI CPPC nominal performance level value for specified CPUs, served fresh from/sys/devices/system/cpu/cpu<N>/acpi_cppc/nominal_perf.--cppc-highest-perfβ the ACPI CPPC highest performance level value for specified CPUs, from/sys/devices/system/cpu/cpu<N>/acpi_cppc/highest_perf.--cppc-nominal-freqβ the ACPI CPPC nominal frequency for specified CPUs, sitting pretty in/sys/devices/system/cpu/cpu<N>/acpi_cppc/nominal_freq.--hwp-lowest-perfβ the HWP lowest performance level for specified CPUs. It readsMSR_HWP_CAPABILITIES(0x771), bits31:24β¨--hwp-efficient-perfβ the HWP most efficient performance level for specified CPUs. ReadsMSR_HWP_CAPABILITIES(0x771), bits23:16.--hwp-guaranteed-perfβ the HWP guaranteed performance level for specified CPUs. ReadsMSR_HWP_CAPABILITIES(0x771), bits15:8.--hwp-highest-perfβ the HWP highest performance level for specified CPUs. ReadsMSR_HWP_CAPABILITIES(0x771), bits7:0.--hwp-min-perfβ the minimum HWP performance level for specified CPUs. ReadsMSR_HWP_REQUEST(0x774), bits7:0. β οΈ But if package-level control is enabled, it reads fromMSR_HWP_REQUEST_PKG(0x772) instead.--hwp-max-perfβ the maximum HWP performance level for specified CPUs. ReadsMSR_HWP_REQUEST(0x774), bits15:8. Same plot twist: if package-level control is on, it goes toMSR_HWP_REQUEST_PKG(0x772) instead.--yamlβ outputs everything in YAML format. Clean, structured, lowkey gorgeous πΈ
π Subcommand 'config' π
Okay bestie, this is the doing mode: configure CPU P-states for specified CPUs. If you don't pass any parameter, it just shows you the current value(s) instead β a lil vibe check, no changes. Use the target CPU specification options to define the subset of CPUs, cores, dies, or packages you're messing with.
-mMECHANISMS,--mechanismsMECHANISMS β a comma-separated list of the mechanisms allowed for configuring CPU P-states. Run--list-mechanismsto see what's available. Heads up: lots of options only support one mechanism (like'sysfs'), while some support multiple (like'sysfs'and'msr'). Mechanisms get tried in the order you list them. By default, all mechanisms are allowed and the most preferred ones are tried first.--list-mechanismsβ shows the available mechanisms for configuring CPU P-states. iykyk π--min-freq[MIN_FREQ] β sets the minimum CPU frequency via/sys/devices/system/cpu/cpu<N>/cpufreq/scaling_min_freq. Default unit is'Hz', but you can also use'kHz','MHz', and'GHz'(like"900MHz").
And the special values, because of course there are special values:
minβ minimum frequency supported by the Linux CPU frequency driver (see'--min-freq-limit').maxβ maximum frequency supported by the Linux CPU frequency driver (see'--max-freq-limit').base,hfmβ base CPU frequency (see'--base-freq').
--max-freq[MAX_FREQ] β basically'--min-freq''s twin, except it sets the maximum CPU frequency via/sys/devices/system/cpu/cpu<N>/cpufreq/scaling_max_freq.--turbo[on|off] β toggles turbo mode globally via sysfs. When it's on, CPUs can exceed the base frequency if the OS and thermal conditions allow it. π₯ For the'intel_pstate'driver, it uses/sys/devices/system/cpu/intel_pstate/no_turbo. For the'acpi-cpufreq'driver, it uses/sys/devices/system/cpu/cpufreq/boost.--epp[EPP] β sets EPP (Energy Performance Preference) using the'sysfs'(preferred) or'msr'mechanism. EPP is a hint to the CPU about energy efficiency versus performance. The value ranges from0-255(maximum energy efficiency all the way to maximum performance), or you can pass a policy name (that one's'sysfs'-only, bestie). The'sysfs'mechanism writes to/sys/devices/system/cpu/cpufreq/policy<N>/energy_performance_preference, while the'msr'mechanism writes toMSR_HWP_REQUEST(0x774), bits31:24.--epb[EPB] β sets EPB (Energy Performance Bias) using'sysfs'(preferred) or'msr'. EPB is also a hint to the CPU on energy efficiency versus performance β note the range runs the other way:0-15(maximum performance to maximum energy efficiency), or a policy name ('sysfs'only, again). The'sysfs'mechanism writes to/sys/devices/system/cpu/cpu<N>/power/energy_perf_bias, while the'msr'mechanism writes toMSR_ENERGY_PERF_BIAS(0x1B0), bits3:0.--intel-pstate-mode[INTELPSTATEMODE] β sets the'intelpstate'driver mode:'active','passive', or'off'. In'active'mode, custom'intelpstate'governors get used. In'passive'mode, the generic Linux governors are employed instead. Writes to/sys/devices/system/cpu/intel_pstate/status.--governor[GOVERNOR] β sets the CPU frequency governor, the lil decision-maker that determines the P-state based on CPU load and other factors. Writes to/sys/devices/system/cpu/cpufreq/policy<N>/scaling_governor.--hwp-min-perf[HWPMINPERF] β sets the minimum HWP performance level for specified CPUs. Writes toMSR_HWP_REQUEST(0x774), bits7:0. β οΈ If package-level control is enabled, it gets overridden so you can have per-CPU control.--hwp-max-perf[HWPMAXPERF] β sets the maximum HWP performance level for specified CPUs. Writes toMSR_HWP_REQUEST(0x774), bits15:8. Same deal: if package-level control is enabled, it's overridden to allow per-CPU control.
And that's a wrap on the options, bestie π the footer of this page reads PEPC-PSTATES(1) β that's the manual's source/version-and-date sign-off, so shoutout to whoever packaged it up for you. Go forth and slay those P-states πβ¨
π¦ where this page comes from
- epel 10: python3-pepc 2.0.7-2.el10_3 Β· BSD-3-Clause
- epel 9: python3-pepc 2.0.7-3.el9 Β· BSD-3-Clause
- fedora 44: python3-pepc 2.0.7-2.fc44 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms