Skipping frames with external monitor plugged in

I noticed after updating this week that my laptop seems to skip frames when I have an external monitor plugged in. I can reproduce it with 100% consistency. I’ve tried restarting, reseating the cable, changing monitors, and changing laptops.

I’m on Arch Linux with KDE 6.2.4 Wayland, and this consistently happens on two different laptops with an AMD Ryzen 7 7840U. I tried Xorg as well, and it still happens. Interestingly, it does not seem to occur on the login screen.

The issue is noticable when moving the cursor in a figure eight, dragging windows around, and is extremely noticeable with a video titled “LCD display motion test 60fps” by Gabor Toth on YouTube (I can’t post links yet :confused: )

Interestingly, it seems fine in OpenArena in fullscreen mode.

Has anyone else been experiencing this? Should I report a bug? It would be great if someone could point me to some logs that might indicate what was going on.

Hi - that’s interesting that it’s only after a recent update. Are you able to see if any system firmware packages or things like that had updates applied around the time this issue started?

Just out of curiosity, does the issue remain if you disable triple buffering in KWin (adding KWIN_DRM_DISABLE_TRIPLE_BUFFERING=1 to your environment variables)? Only asking as I’ve seen at least one bug report filed related to visual stuttering on a system with AMD graphics that seemed connected to triple buffering: 493073 – low (idle) fps/stutters with dynamic triple buffering

For checking system logs, once you plug in the external monitor and start observing the issue, you could run sudo journalctl --boot=0 (for the current boot) and then search for kwin errors to see if anything jumps out as occurring afterward that didn’t happen before the monitor connection.

And just in case there’s a connection somehow…how is the external monitor connected to the laptop and powered?

Thanks for the reply! Yeah, it’s strange. I noticed this problem start sometime last week with an older dell monitor converting HDMI → DVI. I chalked it up to a crappy cable and forgot, but then I came home to my 1440p Acer gaming monitor with HDMI → HDMI and noticed the problem was still happening. I ran a pacman -Syu last week and updated a bunch of stuff.

Logs from 2024-11-28

[2024-11-28T14:15:11-0500] [ALPM] upgraded alsa-ucm-conf (1.2.12-1 -> 1.2.13-2)
[2024-11-28T14:15:11-0500] [ALPM] warning: directory permissions differ on /root/, filesystem: 700  package: 750
[2024-11-28T14:15:11-0500] [ALPM] upgraded filesystem (2024.04.07-1 -> 2024.11.21-1)
[2024-11-28T14:15:11-0500] [ALPM] upgraded alsa-lib (1.2.12-1 -> 1.2.13-1)
[2024-11-28T14:15:11-0500] [ALPM] upgraded assimp (5.4.2-1 -> 5.4.3-1)
[2024-11-28T14:15:11-0500] [ALPM] upgraded sqlite (3.46.1-1 -> 3.47.1-1)
[2024-11-28T14:15:11-0500] [ALPM] upgraded pam (1.6.1-3 -> 1.7.0-1)
[2024-11-28T14:15:11-0500] [ALPM] upgraded systemd-libs (256.8-1 -> 256.8-2)
[2024-11-28T14:15:11-0500] [ALPM] upgraded systemd (256.8-1 -> 256.8-2)
[2024-11-28T14:15:12-0500] [ALPM] upgraded plasma-activities (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:12-0500] [ALPM] upgraded libplasma (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:12-0500] [ALPM] upgraded bluedevil (1:6.2.3-1 -> 1:6.2.4-1)
[2024-11-28T14:15:12-0500] [ALPM] upgraded kdecoration (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded breeze (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded breeze-gtk (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded libjxl (0.11.0-2 -> 0.11.1-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded libpipewire (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded pipewire (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded pipewire-audio (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded pipewire-jack (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded shaderc (2024.2-1 -> 2024.3-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded discover (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded docker-buildx (0.18.0-1 -> 0.19.1-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded docker-compose (2.30.3-1 -> 2.31.0-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded drkonqi (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:13-0500] [ALPM] upgraded gtk-update-icon-cache (1:4.16.6-1 -> 1:4.16.7-1)
[2024-11-28T14:15:14-0500] [ALPM] upgraded electron32 (32.2.5-1 -> 32.2.6-1)
[2024-11-28T14:15:14-0500] [ALPM] upgraded electron33 (33.2.0-1 -> 33.2.1-1)
[2024-11-28T14:15:14-0500] [ALPM] upgraded ell (0.70-1 -> 0.71-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded firefox (132.0.2-1 -> 133.0-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded git (2.47.0-1 -> 2.47.1-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded gst-plugin-pipewire (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded iwd (3.1-1 -> 3.2-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded js115 (115.17.0-1 -> 115.18.0-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded js128 (128.4.0-1 -> 128.5.0-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kactivitymanagerd (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kde-cli-tools (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kde-gtk-config (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kglobalacceld (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded layer-shell-qt (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded libkscreen (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kscreenlocker (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kwayland (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kwin (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kpipewire (6.2.3-2 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded libksysguard (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded ksystemstats (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded libqalculate (5.3.0-1 -> 5.4.0.1-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded milou (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded ocean-sound-theme (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded plasma-activities-stats (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded plasma5support (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded qqc2-breeze-style (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:16-0500] [ALPM] upgraded xdg-desktop-portal-kde (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:16-0500] [ALPM] upgraded plasma-integration (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:16-0500] [ALPM] upgraded ldb (2:4.21.1-1 -> 2:4.21.2-1)
[2024-11-28T14:15:16-0500] [ALPM] upgraded libwbclient (2:4.21.1-1 -> 2:4.21.2-1)
[2024-11-28T14:15:16-0500] [ALPM] upgraded smbclient (2:4.21.1-1 -> 2:4.21.2-1)
[2024-11-28T14:15:16-0500] [ALPM] upgraded qt5-translations (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:16-0500] [ALPM] upgraded qt5-base (5.15.15+kde+r141-1 -> 5.15.16+kde+r130-3)
[2024-11-28T14:15:16-0500] [ALPM] upgraded qt5-svg (5.15.15+kde+r5-1 -> 5.15.16+kde+r5-3)
[2024-11-28T14:15:16-0500] [ALPM] upgraded qt5-x11extras (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:17-0500] [ALPM] upgraded plasma-workspace (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kdeplasma-addons (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kgamma (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded systemsettings (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kinfocenter (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kmenuedit (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded qt5-declarative (5.15.15+kde+r25-1 -> 5.15.16+kde+r22-3)
[2024-11-28T14:15:17-0500] [ALPM] upgraded qt5-wayland (5.15.15+kde+r60-1 -> 5.15.16+kde+r59-3)
[2024-11-28T14:15:17-0500] [ALPM] upgraded openal (1.24.0-1 -> 1.24.1-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded qt5-multimedia (5.15.15+kde+r2-1 -> 5.15.16+kde+r2-3)
[2024-11-28T14:15:17-0500] [ALPM] upgraded qt5-speech (5.15.15+kde+r1-1 -> 5.15.16+kde+r1-3)
[2024-11-28T14:15:17-0500] [ALPM] upgraded krdp (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kscreen (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded ksshaskpass (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kwallet-pam (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kwayland-integration (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded kwrited (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded libjcat (0.2.1-1 -> 0.2.2-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded libzip (1.11.1-1 -> 1.11.2-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded neon (0.33.0-1 -> 0.34.0-1)
[2024-11-28T14:15:17-0500] [ALPM] upgraded opencv (4.10.0-14 -> 4.10.0-15)
[2024-11-28T14:15:18-0500] [ALPM] upgraded oxygen (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded oxygen-sounds (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded pacman (7.0.0.r3.g7736133-1 -> 7.0.0.r6.gc685ae6-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded perl-image-exiftool (13.03-1 -> 13.04-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded pipewire-alsa (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded pipewire-pulse (1:1.2.6-1 -> 1:1.2.7-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-browser-integration (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded polkit-kde-agent (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded powerdevil (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-desktop (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-disks (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-firewall (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-nm (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-pa (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-systemmonitor (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-thunderbolt (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-vault (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-welcome (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded plasma-workspace-wallpapers (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded print-manager (1:6.2.3-1 -> 1:6.2.4-1)
[2024-11-28T14:15:18-0500] [ALPM] upgraded python-pipx (1.6.0-1 -> 1.7.1-1)
[2024-11-28T14:15:19-0500] [ALPM] upgraded qt5-3d (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:19-0500] [ALPM] upgraded qt5-charts (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:19-0500] [ALPM] upgraded qt5-datavis3d (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-doc (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-graphicaleffects (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-location (5.15.15+kde+r7-1 -> 5.15.16+kde+r7-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-quickcontrols (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-quickcontrols2 (5.15.15+kde+r5-1 -> 5.15.16+kde+r5-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-remoteobjects (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-script (5.15.18-1 -> 5.15.18-4)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-scxml (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-sensors (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-serialport (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-tools (5.15.15+kde+r3-2 -> 5.15.16+kde+r3-3)
[2024-11-28T14:15:20-0500] [ALPM] upgraded qt5-webchannel (5.15.15+kde+r3-1 -> 5.15.16+kde+r3-3)
[2024-11-28T14:15:21-0500] [ALPM] upgraded qt5-webengine (5.15.18-2 -> 5.15.18-5)
[2024-11-28T14:15:21-0500] [ALPM] upgraded qt5-websockets (5.15.15+kde+r2-1 -> 5.15.16+kde+r2-3)
[2024-11-28T14:15:21-0500] [ALPM] upgraded qt5-xmlpatterns (5.15.15-1 -> 5.15.16-3)
[2024-11-28T14:15:21-0500] [ALPM] upgraded ruby-irb (1.13.1-1 -> 1.13.1-2)
[2024-11-28T14:15:21-0500] [ALPM] upgraded ruby-rdoc (6.6.3.1-1 -> 6.6.3.1-2)
[2024-11-28T14:15:21-0500] [ALPM] upgraded rust (1:1.82.0-2 -> 1:1.83.0-1)
[2024-11-28T14:15:21-0500] [ALPM] upgraded sddm-kcm (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:21-0500] [ALPM] upgraded systemd-sysvcompat (256.8-1 -> 256.8-2)
[2024-11-28T14:15:22-0500] [ALPM] upgraded virtualbox (7.1.4-1 -> 7.1.4-2)
[2024-11-28T14:15:22-0500] [ALPM] upgraded vte-common (0.78.1-1 -> 0.78.2-1)
[2024-11-28T14:15:22-0500] [ALPM] upgraded vte3 (0.78.1-1 -> 0.78.2-1)
[2024-11-28T14:15:22-0500] [ALPM] upgraded webkit2gtk-4.1 (2.46.3-1 -> 2.46.4-1)

Notably, kwin and friends upgraded from 6.2.3 → 6.2.4

[2024-11-28T14:15:15-0500] [ALPM] upgraded kwayland (6.2.3-1 -> 6.2.4-1)
[2024-11-28T14:15:15-0500] [ALPM] upgraded kwin (6.2.3-1 -> 6.2.4-1)

I tested this with my monitor at the office today which is a 4k Dell monitor over USB-C, and the issue did not occur.

Now I’m sitting at home with my laptop exactly the way it was yesterday, and the issue is no longer happening… of course :joy:

I did notice quite a few of these errors when I snap my windows, but I am unsure if this is related:

Dec 02 18:49:46 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:46 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:46 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:46 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:49 willardpad kernel: perf: interrupt took too long (3353 > 3307), lowering kernel.perf_event_max_sample_rate to 59400
Dec 02 18:49:54 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:54 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:54 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:54 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:54 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:49:54 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:50:00 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:50:00 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:50:00 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:50:00 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:50:00 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 02 18:50:00 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)

Pawing through earlier logs, I found one trace that looked interesting, but I’m not sure what exactly I was doing at the time. This was around 21:00 EST last night.

 WARNING: CPU: 11 PID: 1637 at drivers/gpu/drm/amd/amdgpu/../display/dc/dpp/dcn30/dcn30_dpp.c:534 dpp3_deferred_update+0x101/0x330 [amdgpu]
 Modules linked in: snd_seq_dummy rfcomm snd_hrtimer snd_seq xt_MASQUERADE bridge stp llc nf_conntrack_netlink xfrm_user xfrm_algo tun nf_ta
  industrialio_triggered_buffer ptp drm_buddy ac97_bus snd_intel_sdw_acpi kfifo_buf pps_core cros_ec_dev i2c_algo_bit hid_sensor_iio_common
  ip6table_filter ip6_tables iptable_filter vboxnetflt(OE) vboxnetadp(OE) vboxdrv(OE) pkcs8_key_parser i2c_dev crypto_user loop nfnetlink zr
 CPU: 11 UID: 0 PID: 1637 Comm: kworker/u64:11 Tainted: G           OE      6.12.1-arch1-1 #1 33f4a68ee85c59cb5d6edb747af0349869779b24
 Tainted: [O]=OOT_MODULE, [E]=UNSIGNED_MODULE
 Hardware name: Framework Laptop 13 (AMD Ryzen 7040Series)/FRANMDCP07, BIOS 03.05 03/29/2024
 Workqueue: events_unbound commit_work
 RIP: 0010:dpp3_deferred_update+0x101/0x330 [amdgpu]
 Code: 83 78 e1 00 00 0f b6 90 a8 02 00 00 48 8b 83 70 e1 00 00 8b b0 78 04 00 00 e8 1b 36 0f 00 8b 74 24 04 85 f6 0f 84 5d 01 00 00 <0f> 0b
 RSP: 0018:ffffa45f0065bb90 EFLAGS: 00010202
 RAX: 0000000000000066 RBX: ffff917fb6400000 RCX: 0000000000000004
 RDX: 0000000000000000 RSI: 0000000000000002 RDI: ffff917fbe500000
 RBP: ffff917ff1740000 R08: ffffa45f0065bb94 R09: ffffa45f0065bbc0
 R10: ffffa45f0065bb38 R11: 0000000000000000 R12: 0000000000000000
 R13: ffff917ff1743f88 R14: ffff917ff1745dc8 R15: ffff917fbc77f000
 FS:  0000000000000000(0000) GS:ffff9186de780000(0000) knlGS:0000000000000000
 CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
 CR2: 0000760537a01200 CR3: 000000010e6be000 CR4: 0000000000f50ef0
 PKRU: 55555554
 Call Trace:
  <TASK>
  ? dpp3_deferred_update+0x101/0x330 [amdgpu 84e88e0534dc2928d32f8b075d0992f565877334]
  ? __warn.cold+0x93/0xf6
  ? dpp3_deferred_update+0x101/0x330 [amdgpu 84e88e0534dc2928d32f8b075d0992f565877334]
  ? report_bug+0xff/0x140
  ? handle_bug+0x58/0x90
  ? exc_invalid_op+0x17/0x70
  ? asm_exc_invalid_op+0x1a/0x20
  ? dpp3_deferred_update+0x101/0x330 [amdgpu 84e88e0534dc2928d32f8b075d0992f565877334]
  dc_post_update_surfaces_to_stream+0x1b1/0x2b0 [amdgpu 84e88e0534dc2928d32f8b075d0992f565877334]
  amdgpu_dm_atomic_commit_tail+0x2dd7/0x3c30 [amdgpu 84e88e0534dc2928d32f8b075d0992f565877334]
  ? amdgpu_crtc_get_scanout_position+0x28/0x40 [amdgpu 84e88e0534dc2928d32f8b075d0992f565877334]
  ? srso_alias_return_thunk+0x5/0xfbef5
  ? drm_crtc_vblank_helper_get_vblank_timestamp_internal+0x15d/0x390
  ? srso_alias_return_thunk+0x5/0xfbef5
  ? dma_fence_default_wait+0x8b/0x250
  ? srso_alias_return_thunk+0x5/0xfbef5
  ? wait_for_completion_timeout+0x130/0x180
  ? srso_alias_return_thunk+0x5/0xfbef5
  ? dma_fence_wait_timeout+0x108/0x140
  commit_tail+0x91/0x130
  process_one_work+0x17b/0x330
  worker_thread+0x2ce/0x3f0
  ? __pfx_worker_thread+0x10/0x10
  kthread+0xcf/0x100
  ? __pfx_kthread+0x10/0x10
  ret_from_fork+0x31/0x50
  kthread+0xcf/0x100
  ? __pfx_kthread+0x10/0x10
  ret_from_fork+0x31/0x50
  ? __pfx_kthread+0x10/0x10
  ret_from_fork_asm+0x1a/0x30
  </TASK>
 ---[ end trace 0000000000000000 ]---

My immediate conclusion is that I’ll watch for this issue and continue to try to repro it, and next time it happens I’ll see if I can catch some proper logs. Triggering a sleep, and closing my laptop lid did not induce the problem, so I guess IDK what triggers it.

1 Like

My dad always used to call this mechanic syndrome - a problem with a car that shows up when you run it at home, but disappears when you have it in a shop with all the diagnostic equipment hooked up!

I’ve had problems act like that in the past, so yep, you’ve got the right approach - when it starts acting up again, try to catch what entries are getting put in the logs, if anything is chewing up unusually high CPU usage, things like that.

Best of luck!

1 Like

OK! It just started happening again. I caught these logs from my journalctl:

$ sudo journalctl -f
[sudo] password for wilnil:
Dec 04 19:55:12 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:55:12 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:55:13 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:55:14 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:55:57 willardpad sudo[106373]: pam_unix(sudo:session): session closed for user root
Dec 04 19:55:57 willardpad systemd[48874]: app-Alacritty@a9b7979fa28542b3bc939386eb930437.service: Consumed 8.944s CPU time, 64.3M memory peak.
Dec 04 19:56:20 willardpad systemd[48874]: Started Alacritty - Terminal.
Dec 04 19:56:42 willardpad systemd[48874]: Started Alacritty - Terminal.
Dec 04 19:57:02 willardpad sudo[106612]:   wilnil : TTY=pts/8 ; PWD=/home/wilnil ; USER=root ; COMMAND=/usr/bin/journalctl -f
Dec 04 19:57:02 willardpad sudo[106612]: pam_unix(sudo:session): session opened for user root(uid=0) by wilnil(uid=1000)
Dec 04 19:57:04 willardpad kwin_wayland[48949]: kwin_libinput: Libinput: event6  - Logitech G604 : client bug: event processing lagging behind by 34ms, your system is too slow
Dec 04 19:57:14 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:57:14 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:57:14 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:57:14 willardpad kwin_wayland[48949]: kwin_scene_opengl: 0x2: GL_INVALID_OPERATION in glDrawBuffers(unsupported buffer GL_BACK_LEFT)
Dec 04 19:57:17 willardpad kwin_wayland[48949]: kwin_libinput: Libinput: event6  - Logitech G604 : client bug: event processing lagging behind by 59ms, your system is too slow
Dec 04 19:57:17 willardpad kwin_wayland[48949]: kwin_libinput: Libinput: event6  - Logitech G604 : client bug: event processing lagging behind by 42ms, your system is too slow
Dec 04 19:57:24 willardpad systemd[48874]: Started Dolphin - File Manager.
Dec 04 19:57:37 willardpad systemd[48874]: Started Alacritty - Terminal.

I still am not sure what is causing this, but both Firefox and Slack are taking up quite a bit of CPU right now. Closing them did not help the issue.

Clearly, I think the kwin_libinput is related :sweat_smile: The lag also happens with my trackpad so it’s not just the mouse. Unplugging it had no effect.

Some searches for the error reveal a similar-sounding issue on arch forums. ID 300219 (still can’t post links)

That links to KDE bug 494382 which is a duplicate of 477223

Rebooted and changed mouse. Still occurs:

Dec 04 20:20:13 willardpad kwin_wayland[4270]: kwin_libinput: Libinput: event21 - USB Optical Mouse: client bug: event processing lagging behind by 25ms, your system is too slow

Just so you know, the lags don’t correlate 1:1 with that message. I get a couple of them and then nothing else weird happens in journalctl, but my mouse still lags.

I’ve gone and disabled triple buffering by running

echo export KWIN_DRM_DISABLE_TRIPLE_BUFFERING=1 > /home/wilnil/.config/plasma-workspace/env/triple_buffering.sh

I… can’t tell if that’s helping. It honestly kind of looks like it “lags” whenever my cursor crosses something that makes the shape of the cursor change (like a window border). Is there a way I can be sure that KDE has accepted the env var?

Hmm - triple buffering might not be the culprit after all…the bugs you mentioned there (477223 – Setting an icc profile causes reduced system performance.) are related to having an ICC profile set. Is that the case for you? (It’d be here in System Settings > Display & Monitor)

And about checking the environment variable being recognized, you can use printenv or systemctl --user show-environment to look for it.

Another probably silly question…this laptop doesn’t have a discrete GPU in it, does it? (Not sure what more extensive system info tools you prefer, but inxi -G would confirm that) The fact that it didn’t manifest on a USB-C connected monitor, but does on HDMI, just makes me think of a laptop our family has that is AMD+Nvidia hybrid. In that device, the HDMI port is specifically wired through the Nvidia card, so everything is running on the discrete GPU there. Just a wild theory :slight_smile:

Oops, sorry, I should have mentioned that I do not have a color profile configured, so that probably isn’t the issue.

Also, I have a Framework Laptop 13, with an AMD Ryzen 7 7840U w/ Radeon 780M Graphics. The HDMI port is a module (one of these suckers: Framework | Fix Consumer Electronics) which I believe runs in DisplayPort mode (on Arandr under LXQT X11, my monitor shows up labeled as “DisplayPort 3”)

I can debug more tonight when I get off work.

Phew, yeah this one seems tricky!

One possible piece of info, based on the linked comment here 488860 – Massive frame drops with intel iris xe graphics and triple buffering it might be less likely that the glDrawBuffers error is what’s causing it.

The “Getting debug log output” section here - KWin/Debugging - KDE Community Wiki - has a step that might be helpful, setting the environment variable QT_LOGGING_RULES="kwin_*.debug=true" at least for a short time when it’s acting up to see if more clues are provided in the resulting separate log file?

1 Like

New error: kwin_libinput: Libinput: event8 - PIXA3854:00 093A:0274 Touchpad: kernel bug: Touch jump detected and discarded. See https://wayland.freedesktop.org/libinput/doc/1.27.0/touchpad-jumping-cursors.html for details

Still debugging tonight… turned on debug logging with your environment variable and getting a lot of output.

Dec 06 19:14:19 willardpad slack[11149]: [11149:1206/191419.456369:ERROR:gl_surface_presentation_helper.cc(260)] GetVSyncParametersIfAvailable() failed for 2 times!

Noticing that when I cross the threshold into an inactive window and the mouse lags, I see a lot of this.

Dec 06 19:16:04 willardpad kwin_wayland[9413]: kwin_core: Denied set_cursor request from unfocused client

Other than that, it all looks like pretty normal event output:

Dec 06 19:18:54 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_END), tap state TAP_STATE_DEAD → TAP_EVENT_RELEASE → TAP_STATE_IDLE
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - button state: touch 0 from BUTTON_STATE_NONE    event BUTTON_EVENT_IN_AREA     to BUTTON_STATE_AREA
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_BEGIN), tap state TAP_STATE_IDLE → TAP_EVENT_TOUCH → TAP_STATE_TOUCH
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_NONE → GESTURE_EVENT_FINGER_DETECTED → GESTURE_STATE_UNKNOWN
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] transitions GESTURE_STATE_NONE → GESTURE_STATE_UNKNOWN
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_UNKNOWN → GESTURE_EVENT_HOLD_TIMEOUT → GESTURE_STATE_HOLD
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_UPDATE), tap state TAP_STATE_TOUCH → TAP_EVENT_MOTION → TAP_STATE_DEAD
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_HOLD → GESTURE_EVENT_CANCEL → GESTURE_STATE_NONE
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_HOLD → GESTURE_EVENT_POINTER_MOTION_START → GESTURE_STATE_POINTER_MOTION
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] transitions GESTURE_STATE_HOLD → GESTURE_STATE_POINTER_MOTION
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - button state: touch 0 from BUTTON_STATE_AREA    event BUTTON_EVENT_UP          to BUTTON_STATE_NONE
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_POINTER_MOTION → GESTURE_EVENT_END → GESTURE_STATE_NONE
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_END), tap state TAP_STATE_DEAD → TAP_EVENT_RELEASE → TAP_STATE_IDLE
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - button state: touch 0 from BUTTON_STATE_NONE    event BUTTON_EVENT_IN_AREA     to BUTTON_STATE_AREA
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_BEGIN), tap state TAP_STATE_IDLE → TAP_EVENT_TOUCH → TAP_STATE_TOUCH
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_NONE → GESTURE_EVENT_FINGER_DETECTED → GESTURE_STATE_UNKNOWN
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] transitions GESTURE_STATE_NONE → GESTURE_STATE_UNKNOWN
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_UPDATE), tap state TAP_STATE_TOUCH → TAP_EVENT_MOTION → TAP_STATE_DEAD
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_UNKNOWN → GESTURE_EVENT_POINTER_MOTION_START → GESTURE_STATE_POINTER_MOTION
Dec 06 19:18:55 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] transitions GESTURE_STATE_UNKNOWN → GESTURE_STATE_POINTER_MOTION
Dec 06 19:18:56 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - gesture: [1fg] state GESTURE_STATE_POINTER_MOTION → GESTURE_EVENT_END → GESTURE_STATE_NONE
Dec 06 19:18:56 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - button state: touch 0 from BUTTON_STATE_AREA    event BUTTON_EVENT_UP          to BUTTON_STATE_NONE
Dec 06 19:18:56 willardpad kwin_wayland[9413]: kwin_libinput: Libinput: event8  - tap: touch 0 (TOUCH_END), tap state TAP_STATE_DEAD → TAP_EVENT_RELEASE → TAP_STATE_IDLE

Hmm, the VSync one might be interesting…what are the refresh rate and adaptive sync settings for the external monitors that exhibit the problem? Does the problem remain if you change those - ex. pick a different refresh rate, or flip the status of adaptive sync to the opposite of its current setting (if it’s available)?

For some reason the monitor only supports 60Hz over HDMI. It is a 144Hz gaming monitor with Vsync. Here’s the link for posterity:
https://www.amazon.com/Acer-Predator-XB271HU-2560x1440-Display/dp/B0173PEX20

The settings menu on KDE is very limited when it’s plugged in. I could try fiddling with the settings of the monitor itself, perhaps. Is there a way to fully disable vsync somehow else (or maybe VRR? I’ve heard that can cause problems)

Side Note: Maybe those vsync logs are a red herring. Seems like there’s an electron bug right now: [Bug]: GetVSyncParametersIfAvailable() failed for 1 times! · Issue #32760 · electron/electron · GitHub

Slack was giving me those errors.

The two symptoms I primarily see with this is that when I start moving the cursor with the display unplugged, my mouse skips. When the monitor is plugged in, the skipping is ~constant on the monitor.

Hmm, maybe that could be one thing to check - does the issue occur with literally nothing open other than a core KDE application, like Dolphin or Konsole? And then if it doesn’t, checking as you open your usual applications one-by-one should reveal at least what the problematic interaction is.

And for these monitors, yes if there’s a way to try switching off different settings on them directly / via their on-screen menus, that’s worth trying as well.

That’s a good suggestion. I think I am noticing some kind of pattern, actually: Whenever I mouse over something that changes the cursor icon, like the corner of a window, a text box, or a link, I get a little bit of the lag. It almost feels like my cursor is getting “stuck” while it changes, then catches up. I am going to try to record a video.

To actually answer your question: With nothing on the desktop, or even just one window, I don’t see any of this lag. It only happens when the cursor changes (such as when the shake to enlarge feature kicks in)

It also ONLY happens on the external monitor.

This is really messed up: It doesn’t really show up on video. I think it’s visible-ish about halfway through when I am mousing over “replies, views, activity”. It seems to get stuck there for a frame or two, then snap to where I’d expect it to be.

When I am moving the terminal window around, it’s buttery smooth both in the video and in real life.

The fact that it doesn’t really show up on video makes me go back to thinking about the monitor being 144 Hz, but only supporting 60 Hz over HDMI…does the issue occur if you connect that monitor through a different method (DP or USB-C)? If the graphics card can output relatively smooth video to a screen recording, then maybe the issue is somewhere in that translation between the screen output as rendered by the graphics card, the output as transmitted out via HDMI, and the output as received via HDMI by the monitor?

If that’s not fruitful, then on the idea about the cursor…this Reddit comment is supposed to be related to a bug that’s already been fixed, but just in case - it might be worth trying out either/both of these sets of environment variables: https://www.reddit.com/r/linux_gaming/comments/1c2ey6u/comment/kzasm0j/

export KWIN_DRM_DELAY_VRR_CURSOR_UPDATES=1
export KWIN_FORCE_SW_CURSOR=1

or

export KWIN_DRM_DELAY_VRR_CURSOR_UPDATES=1
export KWIN_DRM_NO_AMS=1
export KWIN_DRM_DONT_FORCE_AMD_SW_CURSOR=1

And, I don’t know if/how useful it might be, but the cursor clue brings up a bug report that at least indicates maybe you’re not the only one: 456760 – Noticeable lag with cursor and window management

1 Like

Unfortunately, neither of those variables seems to have an effect. I tried connecting my computer over a USB-C dock I have that turns USB-C → HDMI, but experienced the same symptoms. I have another dock I can try, and maybe if that doesn’t work, I could try ordering a Framework Display Port module and plug in via Display Port.

Though, I don’t think that would work. I have another basic Dell 1080p monitor I keep in a closet for testing, and that one, over native HDMI (with the same cable) exhibits the same symptoms as my main Acer monitor.

I also tried it over an incredibly cursed USB-C → VGA adapter I had (the Dell also has VGA) and besides refusing to do anything higher than 640x480, the issue persists, which is fascinating. My laptop reports this connection as “DP-3”, so I would assume it’s using some kind of Display Port protocol to power this.

Hmm…OK, trying another idea - have all of these tests so far been on an up-to-date, installed Arch Linux system, running Linux kernel 6.12?

If so, could you try booting the hardware that’s giving you problems from a live USB (Fedora, Ubuntu, pick your favorite :slight_smile: ) and seeing if it reproduces there? (I remember some folks having issues with AMD graphics on kernel 6.12, and thought it was worth a shot since you mentioned it only started with some recent updates)

I just found something interesting:

If I…

  • go to the slack app
  • start a huddle
  • share my external monitor
  • and open the screen sharing on my laptop monitor

The issue disappears. Even just having the thumbnail visible in the corner while slack is on my laptop monitor solves it. What do you make of this?

I think it might be helpful to recap what’s been tried and observed at this point:

Software:

  • Issue started after a large system update ~2 weeks ago
  • Doesn’t happen in a full-screen video game
  • Doesn’t happen if screen-sharing is active
  • Doesn’t appear in screen recording, even if it’s observed on the physical monitor
  • Doesn’t happen if only one window is open
  • Happens most noticeably when cursors change, along with KWin debug message kwin_core: Denied set_cursor request from unfocused client

Hardware:

  • Independent of monitor - happened with old Dell monitor, and new Acer monitor
  • Independent of connection method - happened with HDMI cable, HDMI → DVI cable, USB-C dock, USB → VGA adapter

Is there anything else that sticks out to you so far? If not, one thing to help check would be, have you tried booting from a live USB to see if it reproduces there?

If it’s a live USB with an older version of Plasma/KWin than 6.2.4, and the issue doesn’t reproduce, then I’d feel…moderately confident that at this point it’s worth a bug report for KWin. Looking at the commits that went into 6.2.4, there are two that reference cursor handling, backends/drm: reject cursor updates already in beginFrame (0539f18f) · Commits · Plasma / KWin · GitLab and compositor_wayland: don't commit cursor changes if the layer wasn't actually enabled (04b329a1) · Commits · Plasma / KWin · GitLab . These might have nothing to do with your issue, but it might be a possible clue for investigation?

1 Like