Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add EPP control functionality and UI integration #3635

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

A7GoD
Copy link

@A7GoD A7GoD commented Jan 19, 2025

This change adds EPP slider to control panel for ROG ally.
Under Fans+Power section.

image

@A7GoD A7GoD mentioned this pull request Jan 19, 2025
2 tasks
@A7GoD A7GoD marked this pull request as draft January 19, 2025 19:40
@A7GoD A7GoD marked this pull request as ready for review January 19, 2025 19:41
@seerge
Copy link
Owner

seerge commented Jan 24, 2025

@A7GoD hello,

That's an interesting find. But does this option affect actual processor behavior (especially AMD) cause form what I googled it seem to be specific for Intel?

Also how does it corelate with Power Modes (Best Power Efficiency / Balanced / Best Performance) in windows ?

@A7GoD
Copy link
Author

A7GoD commented Jan 24, 2025

Hi @seerge,
Glad you replied. From what i found when looking online there isn't mention of epp's correlation with manufacturer specific behaviour. AMD and Intel both seem to have different names for things having epp. What I think points closest to epp relating with epp seems to be this article: https://docs.kernel.org/admin-guide/pm/amd-pstate.html

Notice that the value ranges from

Energy Performance Preference (EPP) (RW)¶
This attribute provides a hint to the hardware if software wants to bias toward performance (0x0) or energy efficiency (0xff).

This is quite similar to windows' implementation:

https://learn.microsoft.com/en-us/windows-hardware/customize/power-settings/options-for-perf-state-engine-perfenergypreference

When set to 100, the energy performance preference register is set to 255 to favor energy savings. When set to an intermediate value, the energy performance preference register is programmed to the value: (setting * 255) / 100.

Furthermore i have noticed that when windows mode is set to "silent" in ally, it by default seems to set epp to 60.
I think that the power modes you mentioned don't seem to change epp settings.

I would like to hear your views regarding it, hope I can contribute something to this beautiful project :)
Cheers

@seerge
Copy link
Owner

seerge commented Jan 25, 2025

@A7GoD ok,

I did some benchmarks to see if this setting is actually affects something.

I did run Cyberpunk benchmark on same graphic settings and same power limits (15W and 30W) using my Ally Z1 and set EPP slider to edge states - 0% and to 100% respectively. But benchmark results were pretty much identical, so it seems either AMD CPU ignores this setting completely or windows game mode overrides it and does it's job in balancing power already.

I also did same benchmark on my AMD G14 using iGPU only and iGPU + dGPU even. And again - same identical results.

Did you do any tests by yourself ? Do you see any real-life impact from this setting ?

@A7GoD
Copy link
Author

A7GoD commented Jan 25, 2025

@A7GoD ok,

I did some benchmarks to see if this setting is actually affects something.

I did run Cyberpunk benchmark on same graphic settings and same power limits (15W and 30W) using my Ally Z1 and set EPP slider to edge states - 0% and to 100% respectively. But benchmark results were pretty much identical, so it seems either AMD CPU ignores this setting completely or windows game mode overrides it and does it's job in balancing power already.

I also did same benchmark on my AMD G14 using iGPU only and iGPU + dGPU even. And again - same identical results.

Did you do any tests by yourself ? Do you see any real-life impact from this setting ?

Hi @seerge , I tried to test these myself, and couldn't notice changes, it only happened once for me that gpu clocks were as high as 2700 when epp was set to 100 but when i switched back to 0 it went to normal behaviour not changing again, i will need to dig into the issue more, seems like something is making the system ignore epp settings.
Thanks for testing it from your side as well. I have also noticed that auto controller mode is not working for me, so will try to fix that as well.

@seerge
Copy link
Owner

seerge commented Jan 25, 2025

@A7GoD CPU clocks in idle state already scale quite well when you change windows Power Modes (Power Efficiency would give you same 2.7Ghz)

@A7GoD
Copy link
Author

A7GoD commented Jan 25, 2025

@A7GoD CPU clocks in idle state already scale quite well when you change windows Power Modes (Power Efficiency would give you same 2.7Ghz)

Oh, I meant gpu clocks were 2.7ghz
But which checking the script made by ciphray.bat I found he is setting value for PERFAUTONOMOUSWINDOW as well and disabling gamemode. Seems like there is something that can be done to switch gpu priority, i am trying to grasp what that is. Hopefully I might be able to figure it out.

@A7GoD
Copy link
Author

A7GoD commented Jan 26, 2025

@A7GoD CPU clocks in idle state already scale quite well when you change windows Power Modes (Power Efficiency would give you same 2.7Ghz)

Oh, I meant gpu clocks were 2.7ghz
But which checking the script made by ciphray.bat I found he is setting value for PERFAUTONOMOUSWINDOW as well and disabling gamemode. Seems like there is something that can be done to switch gpu priority, i am trying to grasp what that is. Hopefully I might be able to figure it out.

@seerge i have also noticed that outside any game, when the load is less on both CPU and GPU the slider works as intended as you can see the cpu clocks in both cases:

20250126_134433.jpg

20250126_134417.jpg

When epp is 100% the cpu clocks are considerably lower.

Also, that only works when power plan is applied using ciphray.bat's power profile, and not when set via Asus. So my guess is that epp is not that much effective and cpu starts ignoring the values as soon as it sees higher load. For now am not sure how can this be fixed, as asus and windows seem to start ignoring the epp as soon as they can, which is a bummer. It seems on linux the behaviour is much more consistent with the settings

@seerge
Copy link
Owner

seerge commented Jan 26, 2025

@A7GoD yeah, they are lower - but just changing Power Mode lowers clocks even more. Also keep in mind that on your screenshots you use a High Performance Power Plan (not default Balanced Power Plan even). It's supposed to keep clocks to the roof - cause it was the whole purpose of adding it (for CPU-heavy tasks).

My main observation was that I didn't notice any real-life changes from EPP sliders in apps / games.

If you want to watch videos / save battery - people can use Best Power Efficiency mode, if you want to game - use any other power mode.

@A7GoD
Copy link
Author

A7GoD commented Jan 26, 2025

@A7GoD yeah, they are lower - but just changing Power Mode lowers clocks even more. Also keep in mind that on your screenshots you use a High Performance Power Plan (not default Balanced Power Plan even). It's supposed to keep clocks to the roof - cause it was the whole purpose of adding it (for CPU-heavy tasks).

My main observation was that I didn't notice any real-life changes from EPP sliders in apps / games.

If you want to watch videos / save battery - people can use Best Power Efficiency mode, if you want to game - use any other power mode.

Yes, you're correct, I didn't notice any change either, idk how people in forums and discord servers setup their ally, they seem to mention epp working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants