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

            Bug ID: 489230
           Summary: Excessive amount of _NET_DESKTOP_GEOMETRY
                    PropertyChange slow down the entire Xorg
    Classification: Plasma
           Product: kwin
           Version: git-stable-Plasma/6.1
          Platform: Fedora RPMs
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: platform-x11-standalone
          Assignee: kwin-bugs-n...@kde.org
          Reporter: maxim.kartas...@jetbrains.com
  Target Milestone: ---

Created attachment 171011
  --> https://bugs.kde.org/attachment.cgi?id=171011&action=edit
A C program that illustrates the bug

SUMMARY

Starting with Plasma 6.0.3, Java-based IntelliJ IDEs may slow down the entire X
session making various elements feel sluggish or unresponsive. The issue has
been traced down to the generation of a huge amount of PropertyChange events
for the `_NET_DESKTOP_GEOMETRY` property
(https://specifications.freedesktop.org/wm-spec/1.3/ar01s03.html) when starting
to drag a file from any file manager (Gnome Files in my case).
This can be seen on a simple X11 application found below. Note that the
application itself is not enough to reproduce the sluggishness as it does not
react to `_NET_DESKTOP_GEOMETRY` change in the same heavy-weight manner as
intelliJ IDEs do.

The bug was reported by multiple users here:
https://youtrack.jetbrains.com/issue/JBR-6830

STEPS TO REPRODUCE
1. Log in to a Plasma X11 desktop
2. Download PyCharm Community Edition (or any other IntelliJ IDE)
https://www.jetbrains.com/pycharm/download/?section=linux
3. Run PyCharm and create an empty project
4. Open any graphical file manager
5. Start dragging a file from that file manager over PyCharm's window
6. Note how the dragged file lags behind the mouse pointer; Xorg process is at
100% CPU at this point.
7. Exit PyCharm, wait a couple of seconds
8. Start dragging a file from a file manager again
9. Note how smooth dragging is now

Alternatively, compile (`gcc -lX11 test.c`) and run the C program attached.
Once executed, start dragging a file from a file manager and observe the amount
of messages printed to stdout of that program.

Since the actual desktop geometry (its width and height in pixels) is the same
throughout the lifetime of the application, there should not be any such events
at all.

OBSERVED RESULT

Sluggish drag and lots of `Property _NET_DESKTOP_GEOMETRY changed` messages.

EXPECTED RESULT

Smooth drag and one or no `Property _NET_DESKTOP_GEOMETRY changed` messages.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Fedora 40 
(available in About System)
KDE Plasma Version: 6.1.0
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1

ADDITIONAL INFORMATION
Also reproduces with 6.0.3 and on other Linux distros such as Arch.

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

Reply via email to