intel / pcm

Intel® Performance Counter Monitor (Intel® PCM)
BSD 3-Clause "New" or "Revised" License
2.83k stars 477 forks source link

pcm-power: improve the error message to indicate that the client CPU can't be supported #812

Open bjorn3 opened 3 months ago

bjorn3 commented 3 months ago
$ cat /proc/cpuinfo | head -5
processor       : 0
vendor_id       : GenuineIntel
cpu family      : 6
model           : 154
model name      : 12th Gen Intel(R) Core(TM) i7-12650H

This happens both with the version in the Debian repos as well as the latest commit on the master branch (db66fd7ae362f5ed2b490fc54199ea3a25821414) build from source. The pcm command works fine though.

rdementi commented 3 months ago

this is a known limitation for your CPU: https://github.com/intel/pcm/blob/master/doc/FAQ.md#q5

bjorn3 commented 3 months ago

I see. Would it be possible to improve the error message to indicate that the hardware can't be supported at all rather than just missing an implementation in pcm?

rdementi commented 3 months ago

that is a good idea

bjorn3 commented 3 months ago

By the way https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/4115 mentions that there is a way to diagnose why the package C state doesn't go below C3 that works on laptops. I couldn't find the documentation it referred to. Instead I came across this tool, which I hoped would be useful. Do you happen to know what documentation was referred to or how to diagnose this issue?

rdementi commented 3 months ago

c-states should be still shown on your processor in the main pcm tool. A recent example: https://github.com/intel/pcm/issues/811

rdementi commented 3 months ago

image

bjorn3 commented 3 months ago

I see that it doesn't reach beyond package C3, just like I saw in powertop, but that is not helpful for figuring out why it doesn't reach beyond package C3. All P cores are in C7 the fast majority of the time and all E cores are in C6 the fast majority of the time, so I think it is either a kernel misconfiguration or some hardware that needs to be shutdown, but I don't know which of the two it is and which config/device is at fault. I hoped that pcm-power or some other program could tell me which of these it is.

rdementi commented 3 months ago

I am afraid pcm-power is not going to help you but you can read more about package c6 states and conditions of entering package c6 state for 12th gen core processors here (e.g. the on-package graphics core needs to be powered down): https://edc.intel.com/content/www/us/en/design/ipla/software-development-platforms/client/platforms/alder-lake-desktop/12th-generation-intel-core-processors-datasheet-volume-1-of-2/001/package-c-states/