• Guest, The rules for the P & N subforum have been updated to prohibit "ad hominem" or personal attacks against other posters. See the full details in the post "Politics and News Rules & Guidelines."

Question CPU package power consumption is connected to nVidia GPU P-states which caused CPU to throttle during load

StoykovK

Junior Member
Jul 29, 2021
4
0
6
Recently I decided to switch to Linux and started testing various use-cases. One of them turns to be very interesting.

My laptop is Asus FX753. It has GTX 1050 GPU and 7700HQ. The tests below are made using Ubuntu 21.04 and Windows 10 (20H2).

I tested how does CPU/GPU behave during load on Linux/Windows. I would like to skip all of the findings and focus on only one thing that connects them all - Idle package power consumption (IPPC for short) of the CPU and how it is connected to the dGPU.

1. Using "Power Saver" mode in PRIME SELECT results in using only iGPU and completely turns nVidia off. In this case the IPPC is <2.5W.
2. Using "nVidia on demand" mode in Prime results in using iGPU unless explicitly selected nVidia. In this case both GPUs are always active. No matter how many processes are actually using the nVidia - it is always active! In this case IPPC is ~5-12W.
3. Using "performance" mode in Prime results in using ONLY nVidia gpu. It is always active. In this case IPPC is ~5-12W.

So far turning the dGPU on causes high power consumption on the CPU side which were supposed to be relaxed because its iGPU is not working.

Later on I tried to find why the IPPC is in so broad range - from 5 to 12W and how it is connected to the GPU. Luckily I found it. The answer was in power states of the GPU (P-states). When the GPU is using P0 (max performance) then the IPPC is 5W. In any other case the IPPC is more (up to 12W). It sounds quite counterintuitive but.. it turns out to be true. The faster the GPU runs the less affect it has on the CPU thus the CPU package power consumption is reduced and vise-versa - the slower the GPU runs, the more power CPU drains.

Now let's go to Windows. It has only one GPU mode - "on demand". The difference with Linux is that on Windows when no app is using the nVidia GPU then it is turned off thus resulting in IPPC <2.5W. If any app starts using the nVidia GPU then the IPPC go up to 12W. So on Windows the logic is the same as Linux - the faster the GPU runs, the lower CPU's package power is.
Note: I checked power consumption on Windows on idle. Power of the Core/IA/GX were almost 0, while package is 5-12W when nVidia enabled.

According to all findings the issue is not related to the OS/GPU. Somehow turning dGPU on (no matter of the usage) causes high CPU package power consumption (thus leaving to lower frequencies when CPU is loaded). What could be the reason? Is there something wrong with nVidia drivers for both Windows/Linux? Is there some specific CPU component that is activated when dGPU is running?
 

Mopetar

Diamond Member
Jan 31, 2011
6,119
2,939
136
Could be a case of the laptop having a maximum amount of power it can deliver at any one time and it not being capable of supplying enough for the CPU and GPU to run full out at the same time.
 
  • Like
Reactions: NTMBK

JoeRambo

Golden Member
Jun 13, 2013
1,211
1,112
136
I thought so initially but can this explain why CPU's power consumption goes lower with increasing of the GPU performance?
Does not really need laptop either. I have 1050 in one desktop machine and over remote desktop i was able to pretty much confirm this behavior:
When idle Rest Of Chip in HWInfo64 is ~6.2W, when running say Winrar benchmark same - 6.2W. But running GPU-Z render test to ramp up PCI-E speeds results in just ~2W of power usage.

1627761805525.png


So it seems PCI-E 1.1 mode ends up wasting power in PCI-E link in CPU Package?
Same effect can be seen in 3090, it does not even ramp up clock speeds that much, just going to PCIE3 speeds and going from 3.9W to 1.9W.

1627762164576.png


P.S. It might be possible with some driver hacking on Linux to achieve PCIE3 speeds at all time.
 

zir_blazer

Golden Member
Jun 6, 2013
1,049
273
136
This is weird since supposedly PCIe 1 consumes less power and thus is the favoured Idle setting. Are you planning on sending your findings to a dev? Giving than it is reproducible, it is worth to pester a dev with a bug report.
 

coercitiv

Diamond Member
Jan 24, 2014
4,520
6,151
136
According to all findings the issue is not related to the OS/GPU. Somehow turning dGPU on (no matter of the usage) causes high CPU package power consumption (thus leaving to lower frequencies when CPU is loaded). What could be the reason? Is there something wrong with nVidia drivers for both Windows/Linux? Is there some specific CPU component that is activated when dGPU is running?
Something is abnormal about your system if it hits 12W regularly in idle and not just as an isolated spike, in the sense that having an active dGPU shouldn't push CPU Package Power over 4-6W on average when the system is idle.

In Windows I suggest using HWInfo64 to monitor both CPU Sleep States but more importantly Package Sleep States. HWINfo has a dedicated sleep states residency section in the Sensors Window. Here's my CPU at idle:

1627924167953.png

Here's my Package Power, note the 5.6W average even with an isolated spike to 12W:

1627924893583.png

Note that using a dGPU pushes package power from 1-2W to 4-6W on any Intel Skylake based CPU, no matter if we're talking desktop or mobile. There is also one case I know of where this can happen on iGPU as well, and that is when the laptop is connected to an external monitor. (in that case I noticed the Package C3 residency tends to be very low, but this may vary from one laptop to another)

All of that being said I doubt the higher IPPC is negatively affecting your CPU performance, as this is most likely an idle power consumption issue caused by the CPU not entering Sleep States properly. These extra watts do not eat into the power quota of the CPU when doing actual work, unless the issue is being caused by some faulty component/software that is eating CPU time.

Check on sleep states, if residency is equal or higher than what I have in the pics above, then you're fine... and should look elsewhere to solve throttling problems.
 

StoykovK

Junior Member
Jul 29, 2021
4
0
6
Core C7 Residency is ~96% and Package's is ~80% on idle when dGPU is off. When dGPU is active there is 2-3% percentage drop.

Could you check your IPPC when your dGPU is active at lowest possible frequency?

Also I've checked that this higher IPPC actually eats from CPU power budget and fully loaded CPU with idle dGPU cases ~33W for cores and ~12W for something else resulting in total 45W. When the dGPU is completely inactive then the cores' power goes up to ~42W.
 

coercitiv

Diamond Member
Jan 24, 2014
4,520
6,151
136
Need a much newer HWInfo to show Rest of Chip power, that is where PCIE controllers and probably DMI too are accounted for.
Here's another shot with latest HWInfo.
Screenshot 2021-08-03 120353.png

Also I've checked that this higher IPPC actually eats from CPU power budget and fully loaded CPU with idle dGPU cases ~33W for cores and ~12W for something else resulting in total 45W. When the dGPU is completely inactive then the cores' power goes up to ~42W.
Hmm, that's mighty strange indeed. Unfortunately I don't have a Skylake based laptop to test this.
 

ASK THE COMMUNITY