Bug 454326 - [Wayland] Scrolling in 'Processes' page is choppy/slow for ~30 seconds
Summary: [Wayland] Scrolling in 'Processes' page is choppy/slow for ~30 seconds
Status: RESOLVED FIXED
Alias: None
Product: plasma-systemmonitor
Classification: Applications
Component: general (show other bugs)
Version: 5.25.90
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KSysGuard Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-24 10:54 UTC by Patrick Silva
Modified: 2023-01-19 08:30 UTC (History)
5 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 Patrick Silva 2022-05-24 10:54:08 UTC
STEPS TO REPRODUCE
1. use Wayland session
2. open System Monitor
3. go to 'Processes' page
4. scroll down/up

OBSERVED RESULT
scrolling is choppy/slow. After ~30 seconds the scrolling works as expected.

EXPECTED RESULT
normal scrolling

SOFTWARE/OS VERSIONS
Operating System: KDE neon Unstable Edition
KDE Plasma Version: 5.25.80
KDE Frameworks Version: 5.95.0
Qt Version: 5.15.4
Graphics Platform: Wayland
Comment 1 Nate Graham 2022-05-24 17:02:28 UTC
Hmm, cannot reproduce.
Comment 2 Nagy Tibor 2022-06-14 21:59:38 UTC
I can reproduce this on Neon. Hotspot says the lag comes from KIconEngine, KIconLoader and KIconTheme. So I'd guess the lag comes from loading the process icons.
Comment 3 Nagy Tibor 2022-06-14 22:15:52 UTC
strace says to load a single icon System Monitor searches through a thousand(!) possible icon paths. For every single icon. No wonder why it's so slow.

It also doesn't strip the parameters from the executable line when it construct the possible icon paths. For example when loading icons for vscode it ends up searching for nonsense paths like this.

access("/usr/share/icons/hicolor/48x48/actions/code --type=zygote -.svgz", F_OK) = -1 ENOENT (No such file or directory)
Comment 4 David Redondo 2022-09-19 09:27:47 UTC
Indeed we just use what is displayed in the column
https://invent.kde.org/plasma/plasma-systemmonitor/-/blob/master/src/faces/processtable/contents/ui/ProcessTableView.qml#L163

Can that make that a bit smarter
Comment 5 David Redondo 2023-01-19 08:30:05 UTC
Git commit df0645f0b0bc003ea230347eaea5173a928ad580 by David Redondo.
Committed on 19/01/2023 at 08:27.
Pushed by davidre into branch 'master'.

Process table: Always use binary name for icon lookup

Some processes have all the arguments included in the name, split on
space to only use the binary.
Also lowercase for good measure as most icons tend to be only lower case.

M  +1    -1    src/faces/processtable/contents/ui/ProcessTableView.qml

https://invent.kde.org/plasma/plasma-systemmonitor/commit/df0645f0b0bc003ea230347eaea5173a928ad580