Create lots of files, size doesn't matter as long as they're a lot, e.g. #!/bin/bash mkdir -p /tmp/file-gen dd if=/dev/urandom of=/tmp/file-gen/file-random-0.bin bs=4K count=1 iflag=fullblock for i in $(seq 1 30000); do cp /tmp/file-gen/file-random-0.bin /tmp/file-gen/file-random-$i.bin done Open Dolphin and make sure the "Start a Slideshow" context menu entry is enabled. If it wasn't, also make sure to close all Dolphin instances (since it appears changing the context menu is only effective on new instances). Browse to /tmp with Dolphin, then right click the file-gen dir to bring up the context menu Expected result: context menu appears in a reasonable time Actual result: context menu takes more than 10 or 20 seconds to appear Disabling the Start a Slideshow context menu entry causes the context menu to appear instantly. Useful info: a similar problem is also known for Ark's compress/uncompress actions. So if disabling the slideshow entry (and restarting Dolphin) still doesn't "solve" the problem, make sure to also disable those Ark's context menu entries, too. With the Ark entries TBH I only noticed slow downs when invoking the context menu on a large file selection. With the Gwenview entry the slow down happens in that case as well, but crucially ALSO when just invoking the context menu on the parent directory. Related bugs: https://bugs.kde.org/show_bug.cgi?id=499551, https://bugs.kde.org/show_bug.cgi?id=499595 Operating System: openSUSE Tumbleweed 20250209 KDE Plasma Version: 6.2.5 KDE Frameworks Version: 6.10.0 Qt Version: 6.8.2 Kernel Version: 6.13.1-1-default (64-bit) Graphics Platform: Wayland Processors: 16 × AMD Ryzen 7 7840U w/ Radeon 780M Graphics Memory: 30.7 GiB of RAM Graphics Processor: AMD Radeon 780M Manufacturer: Framework Product Name: Laptop 13 (AMD Ryzen 7040Series) System Version: A7
Created attachment 178138 [details] flamegraph when invoking the context menu on a dir containing 30k 4KB files
Created attachment 178139 [details] enable gwenview's context menu entry
Gwenview is looking if there's any image file in the list of files. Since there are non this takes a very long time.
(In reply to David Redondo from comment #3) > Gwenview is looking if there's any image file in the list of files. Since > there are non this takes a very long time. There is prior research https://bugs.kde.org/show_bug.cgi?id=499551#c7 btw, and the same issue in ark.
Does Dolphin determine the mime types of files when viewing a directory? (or the thumbnailing?). If so, could this be shared?
(In reply to David Redondo from comment #5) > Does Dolphin determine the mime types of files when viewing a directory? (or > the thumbnailing?). I also raised the idea. https://bugs.kde.org/show_bug.cgi?id=499551#c11 https://invent.kde.org/frameworks/kio/-/merge_requests/1813 > If so, could this be shared? Anything is possible. It is done for the selected files already but not for the files within a selected folder. And they are two cases: the current folder (when you right click on a blank area of the current folder), and a selected folder within the current folder. The first case we could share the data, the second not so much, since it might not be loaded by dolphin. So I don't think this optimization is that great and necessary if we have what I suggest in https://invent.kde.org/frameworks/kio/-/merge_requests/1813