SUMMARY *** It seems that whenever kwin gets replaced to apply some settings, and the OpenGL renderer is enabled, kwin becomes sluggish and almost unusable. The only way to fix the issue is either reboot the system, or disable OpenGL via the OpenGLIsUnsafe setting in .config/kwinrc and then run kwin_x11 --replace (this of course disables all effects). *** STEPS TO REPRODUCE 1. Simply run kwin_x11 --replace or just modify some kwin related setting like window decorations. OBSERVED RESULT kwin is restarted but it is now sluggish EXPECTED RESULT kwin should restart without problems SOFTWARE/OS VERSIONS Linux/KDE Plasma: Fedora 35 KDE Edition (available in About System) KDE Plasma Version: 5.24.2 KDE Frameworks Version: 5.91.0 Qt Version: 5.15.2 Kernel version: 5.16.11 Video driver: nouveau GPU: intel/nvidia optimus ADDITIONAL INFORMATION I tried disabling nouveau from boot by setting nouveau.modeset=0 as kernel parameter and thus use only mesa drivers, but the issue remains.
As an additional confirmation that the OpenGL renderer is at fault, when executing KWIN_COMPOSE=<renderer> kwin_x11 --replace, everything is fine when using X (Xrender), but when setting KWIN_COMPOSE=O2 (OpenGL2), the problem starts to show up.
I have the same issue on Kubuntu 21.10 with KDE Backports PPA Operating System: Kubuntu 21.10 KDE Plasma Version: 5.24.3 KDE Frameworks Version: 5.92.0 Qt Version: 5.15.2 Kernel Version: 5.13.0-37-generic (64-bit) Graphics Platform: X11 Processors: 4 × Intel® Core™ i5-7300U CPU @ 2.60GHz Memory: 15,4 GiB of RAM Graphics Processor: Mesa Intel® HD Graphics 620 I cannot reconfigure anything kwin related that restarts kwin, without having a nearly unusable system, framerate of everything drops to about 1-2 fps. My workaround then is to disable compositing by pressing CRTL-SHIFT-F12, but for re-enabling a working compositing I have to logout and back in. The issue also appears when I restart kwin on the console with using "kwin_x11 --replace". Console output: $ kwin_x11 --replace Warning: Setting a new default format with a different version or profile after the global shared context is created may cause issues with context sharing. kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5089:46: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5091:48: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5093:48: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5097:47: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5099:46: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5107:48: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5111:46: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5113:46: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5117:45: this compose sequence is a duplicate of another; skipping line kwin_xkbcommon: XKB: /usr/share/X11/locale/en_US.UTF-8/Compose:5120:46: this compose sequence is a duplicate of another; skipping line OpenGL vendor string: Intel OpenGL renderer string: Mesa Intel(R) HD Graphics 620 (KBL GT2) OpenGL version string: 4.6 (Compatibility Profile) Mesa 21.2.6 OpenGL shading language version string: 4.60 Driver: Intel GPU class: Kaby Lake OpenGL version: 4.6 GLSL version: 4.60 Mesa version: 21.2.6 X server version: 1.20.13 Linux kernel version: 5.13 Requires strict binding: yes GLSL shaders: yes Texture NPOT support: yes Virtual Machine: no kwin_core: XCB error: 10 (BadAccess), sequence: 3598, resource id: 1993, major code: 142 (Composite), minor code: 2 (RedirectSubwindows)
*** This bug has been marked as a duplicate of bug 444536 ***