Closed star-buck closed 5 years ago
just applying the same 2 wallpapers back and forth like 5 times brings it up to this:
current system:
Maybe a Qt Bug. On Neptune with Plasma 5.12 but Qt 5.7 I don't see a big memory usage change when changing wallpapers. It runs in about 180MB plus minus depending on the wallpaper. Never even touching 200MB
David mentioned during a recent meeting that he's done a full rewrite of the image wallpaper code. It's not been posted for review yet.
seems not a Qtbug, is also happening with Plasma 5.12 and Qt5.10 as on Pinebook img: Download any wallpaper via GHNS, then set method to "Scaled and Cropped", then switch between at least 3 wallpapers and simply hit "apply" without closing the config window while having KSYSGUARD opened will show increasingly memory for plasmashell each time you hit "apply".
@eikehein : that doesnt help in case whatever debian or anyone else ships right now though.
Hmm... tested this a few minutes here with changing back and forth. (long video ahead) Finally it did raise the memory a bit but nothing so drastically like you have. Wonder what could cause this. Might be just the thumbnail loading :P https://youtu.be/knukjxGG18c
From what I can tell this is a Qt bug, especially noticeable with slideshow where images repeatedly change: https://bugs.kde.org/show_bug.cgi?id=368838
I tried slamming a QQuickWindow::releaseResources()
call after we unloaded the previous wallpaper with no real effect, though, but I also didn't observe this memory leak here.
could be tried to do a minimal qml that loads in qmlscene continuouly switching the source of an Image to isolate if the problem is actually in Image. (and if there is difference between changing source to an Image which is what the wallpaper is doing now compared to creating and destroying different image components w/releaseresources each time) for the wallpaper in general yeah, I would prefer to wait to work on David's rewrite
important point: memory grows both just hitting apply and keeping always the same dialog open and opening/closing the dialog each time? (this is to exclude something wrong in the dialog, thumbnail loading etc)
this might be related https://bugreports.qt.io/browse/QTBUG-61754 tough my qt build has both patches in but is still somewhat reproducible (about 10 MB every wallpaper switch which is indeed around the size of the final uncompressed image, so somehow Image is still not freeing part of the texture data) the test case attached to that bug report doesn't seem to increase memory a lot while running
the leak seems to be in the blurring happening when the image is smaller then the desktop disabling all that code the leak goes awaty, it may be a leak in the qt GaussianBlur component, but more likely is that regardless that blur fill is used or not, after some switches, 4 images stay always loaded in memory (2 images for the fade anim, and one copy of each of them for the blur fill) that's afaik what David rewrite adresses. interesting to see if keeps climbing or as it seems here, stabilizes after few changes, which would mean.. easy optimizations
If the GaussianBlur
item leaked, David's rewrite would indeed "fix" that as with the new approach a fresh item will be created and the old one destroyed whereas currently we reuse it
Question: Does the rewrite also fix the mouse lag issue in the settings dialog?
Wrong thread, this has nothing to do with mouse lag, please dont hijack topics that are absolutely unrelated and have todo with libinput and co., thanks.
On Feb 28, 2018 4:06 PM, "James Kittsmiller" notifications@github.com wrote:
Question: Does the rewrite also fix the mouse lag issue in the settings dialog?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/blue-systems/plasma-5.13/issues/125#issuecomment-369267425, or mute the thread https://github.com/notifications/unsubscribe-auth/AAzRhnSp9wRQkdw6_UbG_ZUGgHewM2aDks5tZWr8gaJpZM4SRUIX .
Wasn't this fixed with an upstream Qt change in 5.11?
Since my Qt patch I've stopped seeing this issue in KDE bugzilla. Please let me know if it's an issue with Qt 5.11.2 or higher.
I can confirm the fix myself. Also, we backported the fix to Qt 5.9.5 in Kubuntu 18.04 and users there confirmed the fix too.
currently at over 480MB: