Bug 500500 - kwin does not use PreciseTimers in renderloop
Summary: kwin does not use PreciseTimers in renderloop
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: core (show other bugs)
Version: master
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords: efficiency-and-performance
Depends on:
Blocks:
 
Reported: 2025-02-21 02:05 UTC by Apostolos Dimitromanolakis
Modified: 2025-02-24 03:37 UTC (History)
3 users (show)

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


Attachments
patch to switch timer types (977 bytes, text/plain)
2025-02-21 02:05 UTC, Apostolos Dimitromanolakis
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Apostolos Dimitromanolakis 2025-02-21 02:05:45 UTC
Created attachment 178667 [details]
patch to switch timer types

When the renderloop timer is contrsucted no default timer type is set, so the default CoarseTimer is used. CoarseTimer can have a +/- 20% timing offset, which is definetely not ideal for a renderloop.

Suggest using PreciseTimers for this and other timer critical timers in KWin.
Comment 1 Nate Graham 2025-02-22 04:09:06 UTC
Implemented with https://invent.kde.org/plasma/kwin/-/merge_requests/7211!
Comment 2 Yoshio Sato 2025-02-22 13:09:51 UTC
Does it mean more smoothness? (In reply to Nate Graham from comment #1)
> Implemented with https://invent.kde.org/plasma/kwin/-/merge_requests/7211!
Comment 3 Apostolos Dimitromanolakis 2025-02-24 03:37:01 UTC
It will be a little bit smoother. Previously some animations were not drawn with the correct timing, mostly when windows open/close/maximize or you move windows around the screen.  And there should be a little bit less latency in some situations. The difference is not big but is noticable.