SUMMARY STEPS TO REPRODUCE 1. Use system as normal 2. Btop shows high cpu and power usgae by kwin_wayland 3. OBSERVED RESULT kwin_wayland usage cpu constantly, causing higher power draw, stoping cpu from deeper sleep state EXPECTED RESULT kwin_wayland should not be using cpu consultant, it should allow cpu to fall into deeper sleep state when no in active use SOFTWARE/OS VERSIONS Operating System: Fedora Linux 40 KDE Plasma Version: 6.0.4 KDE Frameworks Version: 6.1.0 Qt Version: 6.7.0 Kernel Version: 6.8.7-300.fc40.x86_64 (64-bit) Graphics Platform: Wayland Processors: 16 × 12th Gen Intel® Core™ i5-1240P Memory: 31.1 GiB of RAM Graphics Processor: Mesa Intel® Graphics Manufacturer: Framework Product Name: Laptop (12th Gen Intel Core) System Version: A4 ADDITIONAL INFORMATION
Created attachment 168952 [details] hotspot logs
Created attachment 168953 [details] btop_screenshot
Created attachment 168954 [details] intel_gpu_top_screenshot
Created attachment 168955 [details] powertop_screenshot I left the system to idle for about 10 mins, then took this.
I don't see anything particularly weird in the flamegraph, most of the CPU time is in compositing and processing Wayland events. There is a somewhat odd QThreadPool thing in there taking up a not insignificant part of CPU time, but it's not enough to cause this issue
(In reply to Zamundaaa from comment #5) > I don't see anything particularly weird in the flamegraph, most of the CPU > time is in compositing and processing Wayland events. There is a somewhat > odd QThreadPool thing in there taking up a not insignificant part of CPU > time, but it's not enough to cause this issue I've made few more observations since. The issue is not persistent and constant as it was when I reported it, that seem to have been the right moment where I caught it in full swing. laptop was asleep for few hours after reporting this bug and I didn't see the same CPU usage by kwin_wayland that day. It does reaper occasionality, especially where it does uses significant cpu time just sitting around idling for some reason?
Created attachment 170414 [details] hotspot flamegraph firefox playback
Sorry wrong report
Would help to upload a copy of my perf.data file?
*** Bug 493769 has been marked as a duplicate of this bug. ***
I have a KDE Neon Stable VM that has this issue. It was suffering from the same thing previously, but the high CPU usage went away (probably from the fix in bug 493295) and has returned in the last few days. kwin_wayland takes 180-200% CPU from system start, and then continuously I've got hotpot installed, but I'm not sure how to get data out of it that would be useful. If I can provide data from it, just let me know what you need. Plasma 6.2.1 Frameworks 6.7.0 Qt 6.7.2 Wayland Given that I'm seeing constant high CPU usage, my system might have a different root cause.
(In reply to TraceyC from comment #11) > I've got hotpot installed, but I'm not sure how to get data out of it that > would be useful. If I can provide data from it, just let me know what you > need. I tried `hotspot`, but for some reason it won't let me attach to `kwin_wayland` - only to `kwin_wayland_wrapper` and when I do that I get no results (I think because `kwin_wayland_wrapper` doesn't actually do anything unless `kwin_wayland` crashes). You can use `perf` to generate the call trace data directly, and then - if you want - you can load it in hotspot. I use this command to capture 60 seconds of execution data: sudo perf record -F 1000 -p $(pidof kwin_wayland) -g -- sleep 60
Thanks Oded. Here's the data I got from the VM, let me know if you want any other data. Samples: 113K of event 'cycles:P', Event count (approx.): 333196569442 Children Self Command Shared Object Symbol + 49.66% 0.00% llvmpipe-1 libc.so.6 [.] clone3 + 49.66% 0.00% llvmpipe-1 libc.so.6 [.] start_thread + 49.66% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17c51d6fc + 49.65% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb485b7 + 49.56% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4836b + 49.46% 0.00% llvmpipe-0 libc.so.6 [.] clone3 + 49.46% 0.00% llvmpipe-0 libc.so.6 [.] start_thread + 49.46% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17c51d6fc + 49.43% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb485b7 + 49.33% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4836b + 40.21% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb47d91 + 40.13% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb47d91 + 6.60% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4a3e6 + 6.53% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4a3e6 + 3.93% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4a9c4 + 3.86% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4a9c4 + 3.00% 2.98% llvmpipe-1 [JIT] tid 2605 [.] 0x000079a186696d60 + 2.99% 2.96% llvmpipe-0 [JIT] tid 2605 [.] 0x000079a186696d60 + 1.41% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb488d6 + 1.30% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb488d6 + 1.24% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4ae57 + 1.21% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4ae57 + 1.14% 1.13% llvmpipe-1 [JIT] tid 2605 [.] 0x000079a17e5f57a9 + 1.12% 1.11% llvmpipe-0 [JIT] tid 2605 [.] 0x000079a17e5f57a9 + 1.06% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb49b46 + 1.05% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb49b46 + 0.82% 0.00% kwin_wayland kwin_wayland [.] _start + 0.82% 0.00% kwin_wayland libc.so.6 [.] __libc_start_main@@GLIBC_2.34 + 0.82% 0.00% kwin_wayland libc.so.6 [.] __libc_start_call_main + 0.82% 0.00% kwin_wayland kwin_wayland [.] main + 0.82% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QCoreApplication::exec() + 0.82% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QEventLoop::exec(QFlags<QEventLoop::Proces + 0.82% 0.00% kwin_wayland libQt6Gui.so.6.7.2 [.] QUnixEventDispatcherQPA::processEvents(QFl + 0.82% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QEventDispatcherUNIX::processEvents(QFlags + 0.81% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] 0x000079a195264d34 + 0.80% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QCoreApplication::notifyInternal2(QObject* + 0.80% 0.00% kwin_wayland libQt6Widgets.so.6.7.2 [.] QApplicationPrivate::notify_helper(QObject + 0.77% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QObject::event(QEvent*) + 0.77% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QTimerInfoList::activateTimers() + 0.77% 0.00% kwin_wayland libQt6Core.so.6.7.2 [.] QTimer::timeout(QTimer::QPrivateSignal) + 0.77% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::RenderLoopPrivate::dispatch() + 0.77% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::RenderLoop::frameRequested(KWin::Ren + 0.77% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::WaylandCompositor::composite(KWin::R + 0.72% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4b570 + 0.72% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb49fce + 0.72% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4b570 + 0.69% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb49fce + 0.69% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4ade0 + 0.66% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4b5ec + 0.65% 0.00% llvmpipe-1 kms_swrast_dri.so [.] 0x000079a17cb4b4cf + 0.65% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4ade0 + 0.64% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4b4cf + 0.62% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::Compositor::paintPass(KWin::RenderLa + 0.62% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::SceneDelegate::paint(KWin::RenderTar + 0.62% 0.06% llvmpipe-0 [kernel.kallsyms] [k] asm_exc_page_fault + 0.62% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::WorkspaceScene::paint(KWin::RenderTa + 0.61% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::WorkspaceScene::paintSimpleScreen(KW + 0.61% 0.07% llvmpipe-1 [kernel.kallsyms] [k] asm_exc_page_fault + 0.60% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::WorkspaceScene::paintWindow(KWin::Re + 0.60% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::ItemRendererOpenGL::renderItem(KWin: + 0.59% 0.00% llvmpipe-0 kms_swrast_dri.so [.] 0x000079a17cb4b5ec + 0.55% 0.00% llvmpipe-0 [kernel.kallsyms] [k] exc_page_fault + 0.54% 0.00% llvmpipe-0 [kernel.kallsyms] [k] do_user_addr_fault + 0.53% 0.00% llvmpipe-1 [kernel.kallsyms] [k] exc_page_fault + 0.52% 0.00% llvmpipe-1 [kernel.kallsyms] [k] do_user_addr_fault 0.50% 0.01% kwin_wayland libkwin.so.6.2.1 [.] KWin::ItemRendererOpenGL::createRenderNode 0.48% 0.00% kwin_wayland libkwin.so.6.2.1 [.] KWin::SurfaceItem::preprocess()