Bug 466551 - Increased CPU consumption in apps when you rapidly switch windows by scrolling on Task Manager widget
Summary: Increased CPU consumption in apps when you rapidly switch windows by scrollin...
Status: REPORTED
Alias: None
Product: kwin
Classification: Plasma
Component: performance (other bugs)
Version First Reported In: 5.27.1
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords: wayland-only
Depends on:
Blocks:
 
Reported: 2023-02-27 18:28 UTC by gudvinr+kde
Modified: 2025-07-10 16:09 UTC (History)
4 users (show)

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


Attachments
load (82.02 KB, image/png)
2023-02-27 18:28 UTC, gudvinr+kde
Details
scrolling (84.59 KB, image/png)
2025-07-10 16:07 UTC, gudvinr+kde
Details
idle (84.59 KB, image/png)
2025-07-10 16:07 UTC, gudvinr+kde
Details
scrolling (145.89 KB, image/png)
2025-07-10 16:08 UTC, gudvinr+kde
Details
scrolling (108.88 KB, image/png)
2025-07-10 16:09 UTC, gudvinr+kde
Details

Note You need to log in before you can comment on or make changes to this bug.
Description gudvinr+kde 2023-02-27 18:28:30 UTC
Created attachment 156800 [details]
load

SUMMARY

If I scroll through all open apps on panel, ALL apps that I scroll through start consuming significant amount of CPU (around 10% each). Load drops to zero when all apps idling.

It virtually doesn't matter if I use it with KDE apps or not (e.g. I tested with firefox, systemmanager and dolphin open). kwin process also gets some load here too. So I suspect that wayland is the culprit here. And since diverse set of apps starts to behave in a same way I have some doubts that firefox, systemmanager and dolphin all have same bug at the same time. Well, it could be wayland-client bug still but that's out of scope of what I am able to debug.

STEPS TO REPRODUCE
1. Open some apps
2. Scroll through tasks rapidly using task applet

OBSERVED RESULT
Significant CPU usage for all apps involved

EXPECTED RESULT
Something more moderate I guess?

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.27.1
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.1.12-zen1-1-zen (64-bit)
Graphics Platform: Wayland
Graphics Processor: AMD Radeon RX Vega M GL Graphics
Comment 1 Nate Graham 2023-02-28 21:45:55 UTC
When you do this, KWin is rapidly showing and hiding them, and there are animated transitions, shadows, possible transparency and blur, etc. Not sure There's really a bug here. When you ask the system to do something hard, it takes some resources. :)
Comment 2 gudvinr+kde 2023-02-28 21:54:54 UTC
(In reply to Nate Graham from comment #1)
> When you ask the system to do something hard, it
> takes some resources. :)

I'd agree if only kwin was consuming resources. But it also causes apps to consume quite significant amount of CPU cycles while apps themselves basically not doing any active work. So there's probably something funny going on during interaction between compositor and apps and that is what doesn't seem like a normal thing to me.
Comment 3 gudvinr+kde 2023-02-28 22:31:52 UTC
I also checked out X11 session and well, if you do this there, CPU usage for all processes is less than 10-12%.
From that, Xorg and plasmashell processes consume more than half.
So I am pretty sure that this is quite significant issue when same actions now take 5x more CPU time than old times.
Comment 4 Nate Graham 2023-03-01 15:18:43 UTC
Ok, let's see what KWin people have to say about it.
Comment 5 TraceyC 2025-04-22 19:23:28 UTC
Thank you for the bug report. Unfortunately we were not able to get to it yet. Can we ask you to please check if this is still an issue with Plasma 6.3.4 (the latest released version)?
Comment 6 Bug Janitor Service 2025-05-07 03:47:01 UTC
๐Ÿ›๐Ÿงน โš ๏ธ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME.

For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging.

Thank you for helping us make KDE software even better for everyone!
Comment 7 gudvinr+kde 2025-05-07 11:02:28 UTC
(In reply to TraceyC from comment #5)
> Thank you for the bug report. Unfortunately we were not able to get to it
> yet. Can we ask you to please check if this is still an issue with Plasma
> 6.3.4 (the latest released version)?

As of 6.3.4 situation doesn't seem to be different. You start scrolling through apps, CPU consumption for opened app increases.
But on X11 only plasmashell CPU usage increases significantly.

If plasma consumes ~2% CPU idling, during rapid scrolling (both on X11 and Wayland) it consumes about 10-12%. But on Wayland ALL opened apps also start eating CPU which doesn't happen on X11.

I don't use wayland regularly for a number of reasons so it took some time for me to check it.
Comment 8 TraceyC 2025-05-07 20:45:51 UTC
Thanks for re-testing. The KWin developers will have to take things from here.

For what it's worth, I'm not able to reproduce this on git-master Wayland
Comment 9 gudvinr+kde 2025-07-10 16:07:38 UTC
Created attachment 183130 [details]
scrolling

(In reply to TraceyC from comment #8)
> For what it's worth, I'm not able to reproduce this on git-master Wayland

It's likely a cheating since after update to 6.4 default action for scrolling is "do nothing".

When you enable scrolling, it's all the same again. See how thunderbird having 10% load just because it's participating in scrolling. Compare that to IDLE (which will be in the next screenshot).
Comment 10 gudvinr+kde 2025-07-10 16:07:50 UTC
Created attachment 183131 [details]
idle
Comment 11 gudvinr+kde 2025-07-10 16:08:32 UTC
Created attachment 183133 [details]
scrolling
Comment 12 gudvinr+kde 2025-07-10 16:09:55 UTC
Created attachment 183134 [details]
scrolling

third time's a charm I hope