https://bugs.kde.org/show_bug.cgi?id=377054

            Bug ID: 377054
           Summary: Krunner hangs for 1-2 second before popping when
                    shortcut is pressed.
           Product: krunner
           Version: 5.9.2
          Platform: Gentoo Packages
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: k...@privat.broulik.de
          Reporter: me...@gruntech.org
  Target Milestone: ---

Created attachment 104288
  --> https://bugs.kde.org/attachment.cgi?id=104288&action=edit
Krunner strace.

When using the "run command" shortcut (default: alt+space), it takes ~2s for
the krunner popup to show up on my machine, which is not critical but can get
quite annoying.

After stracing what happens between the shortcut press and the popup, it seems
the main culprit are read and blocking polls on file descriptor 5:

10:42:01.789930 read(5, "\2\0\0\0\0\0\0\0", 16) = 8
10:42:01.789967 poll([{fd=5, events=POLLIN}, {fd=7, events=POLLIN}, {fd=10,
events=POLLIN}, {fd=12, events=POLLIN}, {fd=14, events=POLLIN}, {fd=15,
events=POLLPRI}], 6, 467) = 1 ([{fd=5, revents=POLLIN}])
10:42:01.792028 read(5, "\1\0\0\0\0\0\0\0", 16) = 8
10:42:01.792059 poll([{fd=5, events=POLLIN}, {fd=7, events=POLLIN}, {fd=10,
events=POLLIN}, {fd=12, events=POLLIN}, {fd=14, events=POLLIN}, {fd=15,
events=POLLPRI}], 6, 465) = 0 (Timeout)
10:42:02.257609 read(5, 0x7ffef446f060, 16) = -1 EAGAIN (Resource temporarily
unavailable)
10:42:02.257670 poll([{fd=5, events=POLLIN}, {fd=7, events=POLLIN}, {fd=10,
events=POLLIN}, {fd=12, events=POLLIN}, {fd=14, events=POLLIN}, {fd=15,
events=POLLPRI}], 6, 5) = 0 (Timeout)

This last timeouted poll alone blocks the process for 0.5s. Searching
backwards, it seems fd 5 is an inotify watch on a theme file:

10:41:52.724462 inotify_add_watch(10, "/usr/share/icons/breeze/index.theme",
IN_MODIFY|IN_ATTRIB|IN_MOVED_FROM|IN_MOVED_TO|IN_CREATE|IN_DELETE|IN_DELETE_SELF|IN_MOVE_SELF|IN_DONT_FOLLOW)
= 5

This could be caused by this write that seem to invoke "RestartStyle", on what
I suppose is a DBUS socket ?

10:41:52.909666 write(7,
"\1\f\1\0\10\0\0\0\1\0\0\0\0\0\0\0\20\0\0\0RestartStyle"..., 72) = 72

I do realise this might not be related to krunner but to the theme engine, but
my understanding stops there.

Reproducible: always.

Steps to reproduce:

1. Press "Run command" shortcut (default: alt+space).
2. Popup takes 2s to show up.

Attached the full strace, with comments when the shortcut is pressed and when
the popup actually shows up.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to