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

CPU usage remains higher when you return to normal speed from unthrottle #11189

Closed
tywald opened this issue Jun 17, 2018 · 5 comments
Closed
Milestone

Comments

@tywald
Copy link
Contributor

tywald commented Jun 17, 2018

What happens?

I didn't pay attention to this issue before(if there was) but seems to happen on all PPSSPP versions I tried(1.3-1.6.3).

When you unthrottle/toggle alternative speed(unlimited) for about 5 seconds then return to normal speed the CPU usage remains higher than before you sped up. It will go back down if you pause emulation then resume.
I've activated Intel SpeedStep so the CPU won't run at max frequency all the time unless there is enough load but with this issue it seems to stay at max until you pause then resume.

It's caused by enabling "Force real clock sync (slower, less lag)".

What should happen?

The CPU usage should return to the same level prior to speeding up.

What hardware, operating system, and PPSSPP version? On desktop, GPU matters for graphical issues.

CPU: i7-3770K.
GPU: GTX 680.
OS: Windows 10 Home 64-bit.
Seems to happen on all PPSSPP versions I tried(1.3-1.6.3).

@tywald tywald changed the title CPU usage remains higher prior to unthrottle CPU usage remains higher when you return to normal speed from unthrottle Jun 17, 2018
@unknownbrackets
Copy link
Collaborator

unknownbrackets commented Jun 17, 2018

This could easily be driver heuristics and might also depend on settings. On Windows 7 / i7-3770, my CPU has definitely spun down after releasing unthrottle (not immediately, the driver waits a bit) for a very long time.

I'm not sure there's any way for PPSSPP to control this behavior. If it's related to your GPU or GPU driver, you could try enabling FrameskipUnthrottle in ppsspp.ini. I have a 950.

-[Unknown]

@tywald
Copy link
Contributor Author

tywald commented Jun 17, 2018

Ah I should have tested with a fresh config, it doesn't happen anymore with one. Let me go through and find what setting caused it.

Looks like it's caused by enabling "Force real clock sync (slower, less lag)".
Yeah I can consistently reproduce it with it enabled, turning it off fixes it.

@hrydgard
Copy link
Owner

Ah, that one makes some sense that it could cause something like this.

@unknownbrackets
Copy link
Collaborator

That uses spin locks on Windows (since Windows is embarrassingly incapable of sleeping for < 1ms, unlike Linux, Macs, and dinky little PSPs) - I would expect it to use higher CPU usage always, not just after unthrottling.

-[Unknown]

unknownbrackets added a commit to unknownbrackets/ppsspp that referenced this issue Feb 19, 2019
Fixes hrydgard#11189.  It was often stuck thinking it was constantly running over,
needed a reset on large delay.
@unknownbrackets
Copy link
Collaborator

#11813 fixes this, but possibly not in the way expected. The setting was not working all the time.

After the fix, the setting will cause consistently high CPU usage but also hopefully correctly synchronize for networking (if you have a sufficiently low latency connection) and input lag reasons.

-[Unknown]

@unknownbrackets unknownbrackets added this to the v1.8.0 milestone Feb 19, 2019
unknownbrackets added a commit to unknownbrackets/ppsspp that referenced this issue Feb 19, 2019
Fixes hrydgard#11189.  It was often stuck thinking it was constantly running over,
needed a reset on large delay.
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

No branches or pull requests

3 participants