Bug 412865 - Memory leak when spamming notifications
Summary: Memory leak when spamming notifications
Status: RESOLVED DUPLICATE of bug 442844
Alias: None
Product: plasmashell
Classification: Plasma
Component: Notifications (show other bugs)
Version: 5.16.5
Platform: Arch Linux Linux
: NOR major
Target Milestone: 1.0
Assignee: Kai Uwe Broulik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-12 01:48 UTC by danct12
Modified: 2021-12-08 01:23 UTC (History)
6 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 danct12 2019-10-12 01:48:18 UTC
SUMMARY
When notifications is being spammed, memory will leak.

STEPS TO REPRODUCE
Since notify-send is slow, I'll use notifications from Accessibility.
1. Enable notifications for modifiers and locking keys
2. Enable notification pop-ups for modifier keys when it's active and inactive
3. Play around with the keys
4. Check plasmashell memory usage

OBSERVED RESULT
Memory is being leaked, even when notifications being cleared, still cannot free the memory being used.

I was able to get plasmashell to use up to a GB of RAM.

EXPECTED RESULT
Memory being freed as soon the notifications are cleared.

SOFTWARE/OS VERSIONS
Distro: Arch Linux
Kernel: 4.19.78-1-lts
KDE Plasma Version: 5.16.5
KDE Frameworks Version: 5.62.0
Qt Version: 5.13.1

ADDITIONAL INFORMATION
None
Comment 1 Kai Uwe Broulik 2019-10-15 19:35:03 UTC
Did you clear the notification from history (does it show up there?) or what did you mean by "as soon as it is cleared"?
Comment 2 danct12 2019-10-15 20:45:09 UTC
On Wednesday, October 16, 2019 2:35:03 AM +07 you wrote:
> https://bugs.kde.org/show_bug.cgi?id=412865
> 
> --- Comment #1 from Kai Uwe Broulik <kde@privat.broulik.de> ---
> Did you clear the notification from history (does it show up there?) or what
> did you mean by "as soon as it is cleared"?

Yes, I cleared the notifications.
Comment 3 Kai Uwe Broulik 2019-10-16 16:49:02 UTC
Confirmed. Even if I clear the history and the model is empty, the isn't free'd. :/
Comment 4 Kai Uwe Broulik 2019-10-16 17:19:27 UTC
However, after spamming a bit, it does increase in memory, but not excessively.

Valgrind suggests massive leaks in the graphics driver and OpenGL libraries,  hardly any in notifications themselves. Possibly through the windows we create for each notification.
Comment 5 Fushan Wen 2021-12-08 01:23:06 UTC

*** This bug has been marked as a duplicate of bug 442844 ***