Bug 477917 - Strange adaptive sync behaviour on Plasma 6 Beta 1
Summary: Strange adaptive sync behaviour on Plasma 6 Beta 1
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (other bugs)
Version First Reported In: 5.90.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords: qt6
: 477899 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-12-02 15:33 UTC by Wouter
Modified: 2023-12-07 12:09 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wouter 2023-12-02 15:33:27 UTC
SUMMARY
After updating to Plasma 6 beta 1 there has been some weird Adaptive Sync behaviour for me (on wayland). I could consistently reproduce this by launching games likes Sea of Thieves through steam. I didn't experience this issue in 5.27.9. When Adaptive Sync is set to automatic it won't activate and when set to always cursor movement doesn't impact refresh rate.

STEPS TO REPRODUCE
- Mouse problem:
1. Set Adaptive Sync to always
2. Set monitor refreshrate higher than 60hz

- Adaptive Sync Automatic problem:
1. Set Adaptive Sync to automatic.
2. Set monitor refreshrate higher than 60hz
2. Launch a game (with proton?)
3. Monitor will still be locked to max refresh rate.

OBSERVED RESULT
When playing most games Adaptive Sync will not activate on some games. Furthermore after launching a game that doesn't behave correctly (such as Sea of Thieves) games that did behave correctly (Quake II RTX) will also not work anymore and will also be locked to max refresh. The only ways I could find to get games that behaved correctly working again is to reboot or set Adaptive Sync to always. When Adaptive Sync is set to always, however, cursor movement doesn't impact refresh rate resulting in a sluggish desktop experience.

EXPECTED RESULT
On plasma stable if Adaptive Sync is set to automatic it will almost always lock refresh rate to game frame rate, unless you move your cursor, then refresh rate would lock to max refresh. This is ideal behaviour in my opinion. 

SOFTWARE/OS VERSIONS
- Plasma 5 Stable (correct behaviour):
KDE Plasma Version: 5.27.9
KDE Frameworks Version: 5.112.0
Qt Version: 5.15.11
Kernel: 6.6.3-zen

- Plasma 6 Beta (incorrect behaviour):
KDE Plasma Version: 5.90.0
KDE Frameworks Version: 5.264.0
Qt Version: 6.6.1
Kernel: 6.6.3-zen

ADDITIONAL INFORMATION
I am using AMDGPU (RX 7900 XTX) with Mesa 23.2.1 and Proton-experimental on steam.
I measured the refresh rate using the refresh rate overlay of my monitor (Acer X27P).
Comment 1 Wouter 2023-12-06 23:59:08 UTC
To add more information to this report:
I observed that when I disconnect my second monitor, instead of disabling it, the automatic Adaptive Sync would almost work like normal.
Comment 2 Zamundaaa 2023-12-07 12:09:11 UTC
I checked what's happening, and KWin is doing everything correctly - this is a kernel bug. You can follow https://gitlab.freedesktop.org/drm/amd/-/issues/3034 for more details
Comment 3 Zamundaaa 2023-12-07 12:09:29 UTC
*** Bug 477899 has been marked as a duplicate of this bug. ***