Bug 415950 - 100% CPU usage of plasmashell
Summary: 100% CPU usage of plasmashell
Status: RESOLVED FIXED
Alias: None
Product: plasma-browser-integration
Classification: Plasma
Component: Firefox (show other bugs)
Version: unspecified
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Kai Uwe Broulik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-01-07 01:24 UTC by Mal Haak
Modified: 2020-01-08 23:37 UTC (History)
0 users

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


Attachments
Screenshot of atop output. (170.16 KB, image/png)
2020-01-07 01:24 UTC, Mal Haak
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mal Haak 2020-01-07 01:24:38 UTC
Created attachment 124949 [details]
Screenshot of atop output.

SUMMARY

Arch Linux 
plasma-meta 5.17-1 
kdebase-meta 19.12-1 
Firefox 71.0 
Plasma Integration 1.7

When Firefox generates a Download Notification in KDE CPU the CPU usage of plasmashell skyrockets. 

If I disable the Plasma integration, this does not happen. Also it does not happen for Media playback, despite also having a progress bar. 


STEPS TO REPRODUCE
1. Open Firefox
2. Enable Plasma integration plugin in firefox
3. Start a download

OBSERVED RESULT
plasmashell CPU usage goes to 100% (or higher)

EXPECTED RESULT
Download notification created with tracked progress, but not 100% CPU usage and increased GPU usage.

SOFTWARE/OS VERSIONS

Arch Linux packages
plasma-meta 5.17-1 
kdebase-meta 19.12-1 
Firefox 71.0 
Plasma Integration 1.7

Operating System: Arch Linux 
KDE Plasma Version: 5.17.4
KDE Frameworks Version: 5.65.0
Qt Version: 5.14.0
Kernel Version: 5.4.8-arch1-1
OS Type: 64-bit
Processors: 12 × Intel® Core™ i7-9750H CPU @ 2.60GHz
Memory: 15.5 GiB of RAM


ADDITIONAL INFORMATION
Due to the increased GPU usage, I can only assume its getting updated very frequently from firefox plugin and this is causing excessive redraws. Probably needs a tweak in the Firefox plugin to send updates less frequently. Or some kind of delay on the Plasma side to only actually update the notification less frequently. But I'm just spit balling here.
Comment 1 Kai Uwe Broulik 2020-01-08 12:40:24 UTC
Download status is updated only every second.

I believe it's the typical busy indicator (the spinning icon in your tray) causing excess CPU issue on some GPUs bug...
Comment 2 Mal Haak 2020-01-08 23:37:47 UTC
(In reply to Kai Uwe Broulik from comment #1)
> Download status is updated only every second.
> 
> I believe it's the typical busy indicator (the spinning icon in your tray)
> causing excess CPU issue on some GPUs bug...

That could well be the issue however I don't see this issue with other tasks that cause the spinning icon, say a copy in Dolphin or NetworkManager trying to connect to wifi. 

Wait, I just tested the browser integration and its not doing it. Was a fix for this busy indicator pushed recently? 

I think I've updated since I lodged this bug report.

Yep I have,

Operating System: Arch Linux 
KDE Plasma Version: 5.17.5
KDE Frameworks Version: 5.65.0
Qt Version: 5.14.0
Kernel Version: 5.4.8-arch1-1
OS Type: 64-bit
Processors: 12 × Intel® Core™ i7-9750H CPU @ 2.60GHz
Memory: 15.5 GiB of RAM

I also have an update to the NVIDIA driver that also seems to have fixed/changed DPI detection to match behavior seen on Intel. So that's a plus. 

Anyway, it seems to be working so I'm going to close my ticked as resolved.