libretro / libretro/RetroArch

Enabling "Sync to Exact Content Framerate" causes a GPU usage % drop when using RetroArch's Pause (default hotkey "p") and WASAPI driver

Open
#18,306 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
14.1k
Forks
2.2k
Avg merge
7h 35m
Merged PRs (30d)
51

Description

Is there an existing issue for this?
  • This is a bug in RetroArch frontend
  • I have searched the existing issues
Description

After you pause/unpause using RetroArch's pause (which is also triggered by alt-tabbing), GPU usage gets a permanent hit, causing audio crackles and slightly more unstable framepacing.

I spent around 2 hours tweaking and testing every single option, one by one, related to audio and vsync and this has been the culprit. At first I thought it was the audio driver, because switching from WASAPI to any other fixed the issue, but WASAPI shouldn't lower GPU usage after a pause on itself.

So, to get this, you need WASAPI audio driver, FreeSync/GSYNC option enabled, and then pause/unpause with RetroArch (not the game's own pause).

You also need a decent tool to observe framepacing, Steam has a great one now.

Expected behavior

GPU usage remains normal after unpausing/resuming.

Steps to reproduce the bug
  1. Use a clean RetroArch install
  2. Enable Sync to Exact Content Framerate in Video settings
  3. Save settings and restart RetroArch
  4. Load a game
  5. Enable your framepacing tool (Steam / MSI Afterburner, etc.)
  6. In-game, and when there's music, press the letter "p" on the keyboard twice
  7. Observe the graphs and listen to the music
Version/Commit

1.21.0 (Steam)

Bisect Results

No response

Present in the nightly version

I don't know

Platform & operating system

Windows 11 25H2

Affected Cores

No response

Environment information
  • As mentioned, this issue only happens with WASAPI
  • Issue happens with vulkan and d3d11, albeit slightly differently
  • Tested with an AMD 6650 XT, Adrenaline's RetroArch settings are defaults
  • Issue is easier to be heard when using a very heavy Mega Bezel (Guest's is a good one)
  • Parameters tested that werent' the cause of the issue: other video drivers, vsync swap, adaptive vsync, exclusive and windowed fullscreen, d3d12/11, wasapi sinc/cc/nearest, wasapi quality
Relevant log output

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce on Windows 11 with WASAPI, Sync to Exact Content Framerate, FreeSync or GSYNC, and the default pause hotkey; compare GPU usage, framepacing, and audio before and after pausing. Check the video and audio behavior with Vulkan and D3D11, and consider the issue done when unpausing no longer causes the reported persistent GPU and audio impact.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.