(Regression) kwin_wayland compositor bypass broken in mesa 21.0 for vulkan apps
In currently unreleased version of kwin with fullscreen unredirection, the feature breaks with mesa 21.0 (for vulkan applications only). It used to work fine in mesa 20.3.4.
Steps to reproduce
Issue is currently a little difficult to reproduce since it needs the git version of kwin (kwin 5.22 should have compositor bypass). The latest git version of kwin, kwayland, and kwayland-server need to be compiled and installed.
Then, simply run any vulkan games and notice increased input lag and stuttering. I tried Risk of Rain 2 and Overwatch. Overwatch exhibits stuttering in main menu and practice range, and Risk of Rain 2 has laggy cursor under "Alternate gamemode"->"Prismatic trials" menu.
System: Host: rajdeep-PC Kernel: 5.11.13-zen1-1-zen x86_64 bits: 64 compiler: gcc v: 10.2.0 Desktop: KDE Plasma 5.21.4 tk: Qt 5.15.2 wm: kwin_wayland dm: LightDM, SDDM Distro: Antergos Linux base: Arch Linux CPU: Info: 8-Core model: AMD Ryzen 7 1700 bits: 64 type: MT MCP arch: Zen rev: 1 cache: L2: 4 MiB flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm bogomips: 114988 Speed: 2905 MHz min/max: 1550/3600 MHz boost: enabled Core speeds (MHz): 1: 2905 2: 2994 3: 3106 4: 3455 5: 3057 6: 3128 7: 2987 8: 3002 9: 3002 10: 3220 11: 3071 12: 3429 13: 3046 14: 3056 15: 3136 16: 3024 Graphics: Device-1: Advanced Micro Devices [AMD/ATI] Vega 10 XL/XT [Radeon RX Vega 56/64] vendor: Sapphire Limited driver: amdgpu v: kernel bus-ID: 0d:00.0 chip-ID: 1002:687f Device-2: Microsoft LifeCam HD-3000 type: USB driver: snd-usb-audio,uvcvideo bus-ID: 3-1:2 chip-ID: 045e:0810 Display: wayland server: X.org 1.20.10 compositor: kwin_wayland driver: loaded: amdgpu resolution: <missing: xdpyinfo> (Should be 3840x2160) OpenGL: renderer: Radeon RX Vega (VEGA10 DRM 3.40.0 5.11.13-zen1-1-zen LLVM 11.1.0) v: 4.6 Mesa 21.1.0-devel (git-80b96a2158) direct render: Yes
- DXVK version: 1.8.1 (or any other)
- Wine/Proton version: Proton 6.3-2 (for Risk of Rain 2) and Wine 6.4 (for Overwatch)
Issue did not happen in Mesa 20.3.4, and started happening as soon as I upgraded to 21.0.1. I regressed the issue down to commit d248c911. Reverting that commit in latest git snapshot of mesa resolves the issue. I've attached the reversion patch that solved the issue for me.