Created attachment 375564 [details] Screenshot with output of htop, iotop, vmstat and free commands KDE 4.13. When using krunner (Alt+F2) with desktop search, sometimes it can consume a huge amount of memory, often freezing the system due to continuous swap. Steps to reproduce (100% reproducible): 0. Ensure that "Desktop Search" plugin is active - check in settings of krunner. 1. Enter Krunner (Alt+F2) 2. Type "1+2+3" Almost immediately the memory consumption will spike (from ~0.5G to ~1.4G in my case according to KDE widget). According to htop the memory is consumed by kdeinit4 processes. After closing krunner, the memory is not released. Logout/login (or Ctrl+Alt+Backspace when the system is frozen) helps to release the memory. The effect disappears a soon as "Desktop Search" plugin of the krunner is disabled. Additional information: semantic-desktop USE flag is disabled for whole system except kdelibs. When semantic-desktop USE flag was enabled, eventually something (I guess it was desktop search) started to freeze my system (high memory consumption, aggressive swapping). I have hard-rebooted the system, added home directly to exception list (in System Settings > Desktop Search) and after that recompiled system without USE flag. Attachments: - screenshot with the screen when the problem is there as well as output htop (sort criteria: %mem), iotop, vmstat, free before and after the problem. - versions and USE flags of kde packages. - emerge --info
Created attachment 375566 [details] emerge --info
Created attachment 375568 [details] emerge --nodeps -pv `qlist -IC kde-base/*`
I confirm this on my Gentoo desktop running kde-4.13 with semantic-desktop USE-flag. Since I've added all my media library to desktop search, krunner consumes ~5Gb memory while reproducing those steps.
KDE SC 4.13.1 is now in tree available. Please test.
(In reply to Johannes Huber from comment #4) > KDE SC 4.13.1 is now in tree available. Please test. KDE SC 4.13.3 is in tree since yesterday. Please test.
(In reply to Johannes Huber from comment #5) > (In reply to Johannes Huber from comment #4) > > KDE SC 4.13.1 is now in tree available. Please test. > > KDE SC 4.13.3 is in tree since yesterday. Please test. This is not resolved in 4.13.3 I don't see a problem with 4 arithmetic ops. The problem is when calc.ing exponential numbers. Try to play with the numbers below. You will see 100-200MB sudden allocations and then left overs which are almost cleaned on next alt+f2 before new op. Then be prepared for the huge instant malloc (1-2GB) that will make your system unresponsive. If you can restore from there, you can also see 1-2GB leak (assuming krunner survived linux oom). 2^2 2^22 2^2222 22^2222 222^2222 22^2 2^22
Does this happen only on calculation inputs?
(In reply to Johannes Huber from comment #7) > Does this happen only on calculation inputs? Interesting questions. I am actively using krunner for desktop search and almost for all other plugins. No complaint with other inputs (e.g. lock, mount, 508556, kcalc, etc.). But note this. Both the expressions 22^2 and =22^2 cause huge memory consumption whether Calculator plugin of krunner is *enabled* or *disabled*. This is fatal. It eats up the entire memory available, oom ends up killing system services after user apps to free space.
(In reply to Fatih Tümen from comment #8) > Interesting questions. > > I am actively using krunner for desktop search and almost for all other > plugins. No complaint with other inputs (e.g. lock, mount, 508556, kcalc, > etc.). > > But note this. Both the expressions 22^2 and =22^2 cause huge memory > consumption whether Calculator plugin of krunner is *enabled* or *disabled*. > > This is fatal. It eats up the entire memory available, oom ends up killing > system services after user apps to free space. OK, please report this upstream as we can't do anything about it on distribution level.
(In reply to Johannes Huber from comment #9) > (In reply to Fatih Tümen from comment #8) > > Interesting questions. > > > > I am actively using krunner for desktop search and almost for all other > > plugins. No complaint with other inputs (e.g. lock, mount, 508556, kcalc, > > etc.). > > > > But note this. Both the expressions 22^2 and =22^2 cause huge memory > > consumption whether Calculator plugin of krunner is *enabled* or *disabled*. > > > > This is fatal. It eats up the entire memory available, oom ends up killing > > system services after user apps to free space. > > OK, please report this upstream as we can't do anything about it on > distribution level. Thanks. It seems to be a rather long standing bug there. Joined the convo. https://bugs.kde.org/show_bug.cgi?id=224287