https://bugs.kde.org/show_bug.cgi?id=469777
Bug ID: 469777 Summary: KWin since 5.27.5 uses 1 CPU core at 100% whenever something is using PipeWire to capture the screen Classification: Plasma Product: kwin Version: 5.27.5 Platform: Archlinux OS: Linux Status: REPORTED Severity: normal Priority: NOR Component: wayland-generic Assignee: kwin-bugs-n...@kde.org Reporter: putr...@gmail.com Target Milestone: --- SUMMARY After updating to 5.27.5 whenever something uses PipeWire to capture the screen (I tried OBS, Krfb and Firefox) KWin starts using 100% of one CPU core, even when the app isn't doing anything with the screen capture (like having OBS open without it streaming/recording or Krfb with no active connections). On my system with 8 cores and 16 threads that translates to about 6-7% overall CPU usage, but it also causes the CPU to use its turbo state constantly to keep up as a result. Reverting to KWin 5.27.4.1 makes the CPU usage go back down to more normal levels, and building KWin 5.27.4.1 with this MR (https://invent.kde.org/plasma/kwin/-/merge_requests/3970, screencast: Offer the real framerate range we have available) applied to it causes the issue to come back. I guess that MR might just be exacerbating an existing issue though, I have been getting `kwin_screencast: Dropping a screencast frame because the compositor is slow` messages appear repeatedly in journalctl anytime a screencast session is active, but with 5.27.5 as well as with 5.27.4.1 with that MR applied I get way more of those (from like 20 per second to well over 1000 per second). With Krfb in particular the issue is particularly terrible, even after closing it the CPU usage remains at the same high level. STEPS TO REPRODUCE 1. Update to KWin 5.27.5 or build KWin 5.27.4.1 with the aforementioned MR applied 2. Start a screencast session (either from OBS, Firefox or Krfb) OBSERVED RESULT KWin's CPU usage is ridiculously high. EXPECTED RESULT KWin should not consume so much CPU. SOFTWARE/OS VERSIONS Operating System: Arch Linux KDE Plasma Version: 5.27.5 KDE Frameworks Version: 5.105.0 Qt Version: 5.15.9 Kernel Version: 6.3.2-arch1-1 (64-bit) Graphics Platform: Wayland Processors: 16 × AMD Ryzen 7 6800H with Radeon Graphics Memory: 14.9 GiB of RAM Graphics Processor: AMD Radeon Graphics Manufacturer: HP Product Name: OMEN by HP Gaming Laptop 16-n0xxx -- You are receiving this mail because: You are watching all bug changes.