SUMMARY Using an nvidia wayland session I've observered as high as 40% CPU on kwin_wayland while simply moving the mouse around the desktop. STEPS TO REPRODUCE 1. Start a nvidia wayland session 2. Open ksysguard 3. Move the mouse around quickly in a circle OBSERVED RESULT CPU usage spikes significantly EXPECTED RESULT Minimal impact on CPU usage
I've noticed significantly higher CPU with kwin_wayland over kwin_x11 as well. I'm using AMDGPU (Ryzen 4500U, Renoir).
Does kwin use opengl compositing? Can you post the output of `qdbus org.kde.KWin /KWin supportInformation`?
Yes, it's using opengl. KWin Support Information: The following information should be used when requesting support on e.g. https://forum.kde.org. It provides information about the currently running instance, which options are used, what OpenGL driver and which effects are running. Please post the information provided underneath this introductory text to a paste bin service like https://paste.kde.org instead of pasting into support threads. ========================== Version ======= KWin version: 5.22.5 Qt Version: 5.15.2 Qt compile version: 5.15.2 XCB compile version: 1.14 Operation Mode: X11 only Build Options ============= KWIN_BUILD_DECORATIONS: yes KWIN_BUILD_TABBOX: yes KWIN_BUILD_ACTIVITIES: yes HAVE_DRM: yes HAVE_GBM: yes HAVE_EGL_STREAMS: yes HAVE_X11_XCB: yes HAVE_EPOXY_GLX: yes HAVE_WAYLAND_EGL: yes X11 === Vendor: The X.Org Foundation Vendor Release: 12013000 Protocol Version/Revision: 11/0 SHAPE: yes; Version: 0x11 RANDR: yes; Version: 0x14 DAMAGE: yes; Version: 0x11 Composite: yes; Version: 0x4 RENDER: yes; Version: 0xb XFIXES: yes; Version: 0x50 SYNC: yes; Version: 0x31 GLX: yes; Version: 0x0 Decoration ========== Plugin: org.kde.breeze Theme: Plugin recommends border size: None Blur: 0 onAllDesktopsAvailable: true alphaChannelSupported: true closeOnDoubleClickOnMenu: false decorationButtonsLeft: decorationButtonsRight: 5 borderSize: 0 gridUnit: 10 font: Noto Sans,10,-1,5,50,0,0,0,0,0 smallSpacing: 2 largeSpacing: 10 Platform ========== Name: KWin::X11StandalonePlatform Cursor ====== themeName: Breeze_Snow themeSize: 24 Options ======= focusPolicy: 0 xwaylandCrashPolicy: xwaylandMaxCrashCount: 3 nextFocusPrefersMouse: false clickRaise: true autoRaise: false autoRaiseInterval: 0 delayFocusInterval: 0 shadeHover: false shadeHoverInterval: 250 separateScreenFocus: false placement: 4 focusPolicyIsReasonable: true borderSnapZone: 10 windowSnapZone: 10 centerSnapZone: 0 snapOnlyWhenOverlapping: false rollOverDesktops: true focusStealingPreventionLevel: 1 operationTitlebarDblClick: 5015 operationMaxButtonLeftClick: 5000 operationMaxButtonMiddleClick: 5015 operationMaxButtonRightClick: 5014 commandActiveTitlebar1: 0 commandActiveTitlebar2: 28 commandActiveTitlebar3: 2 commandInactiveTitlebar1: 4 commandInactiveTitlebar2: 28 commandInactiveTitlebar3: 2 commandWindow1: 7 commandWindow2: 8 commandWindow3: 8 commandWindowWheel: 28 commandAll1: 14 commandAll2: 3 commandAll3: 10 keyCmdAllModKey: 16777250 showGeometryTip: false condensedTitle: false electricBorderMaximize: false electricBorderTiling: true electricBorderCornerRatio: 0.25 borderlessMaximizedWindows: false killPingTimeout: 5000 hideUtilityWindowsForInactive: true compositingMode: 1 useCompositing: true hiddenPreviews: 1 glSmoothScale: 2 xrenderSmoothScale: false glStrictBinding: true glStrictBindingFollowsDriver: true glCoreProfile: true glPreferBufferSwap: 101 glPlatformInterface: 1 windowsBlockCompositing: true latencyPolicy: renderTimeEstimator: Screen Edges ============ desktopSwitching: false desktopSwitchingMovingClients: false cursorPushBackDistance: 1x1 timeThreshold: 150 reActivateThreshold: 350 actionTopLeft: 0 actionTop: 0 actionTopRight: 0 actionRight: 0 actionBottomRight: 0 actionBottom: 0 actionBottomLeft: 0 actionLeft: 0 Screens ======= Multi-Head: no Active screen follows mouse: yes Number of Screens: 1 Screen 0: --------- Name: eDP Geometry: 0,0,1920x1080 Scale: 1 Refresh Rate: 60.001 Compositing =========== Compositing is active Compositing Type: OpenGL OpenGL vendor string: AMD OpenGL renderer string: AMD RENOIR (DRM 3.42.0, 5.14.2-1-MANJARO, LLVM 12.0.1) OpenGL version string: 4.6 (Compatibility Profile) Mesa 21.2.1 OpenGL platform interface: GLX OpenGL shading language version string: 4.60 Driver: RadeonSI GPU class: Vega OpenGL version: 4.6 GLSL version: 4.60 Mesa version: 21.2.1 X server version: 1.20.13 Linux kernel version: 5.14.2 Direct rendering: Requires strict binding: yes GLSL shaders: yes Texture NPOT support: yes Virtual Machine: no OpenGL 2 Shaders are used Loaded Effects: --------------- kwin4_effect_squash kwin4_effect_login kwin4_effect_fullscreen kwin4_effect_maximize kwin4_effect_fadingpopups kwin4_effect_morphingpopups kwin4_effect_logout kwin4_effect_sessionquit kwin4_effect_frozenapp kwin4_effect_scale kwin4_effect_windowaperture kwin4_effect_dialogparent slidingpopups slide screenshot desktopgrid colorpicker presentwindows highlightwindow blur startupfeedback screenedge kscreen Currently Active Effects: ------------------------- blur Effect Settings: ---------------- kwin4_effect_squash: pluginId: kwin4_effect_squash isActiveFullScreenEffect: false kwin4_effect_login: pluginId: kwin4_effect_login isActiveFullScreenEffect: false kwin4_effect_fullscreen: pluginId: kwin4_effect_fullscreen isActiveFullScreenEffect: false kwin4_effect_maximize: pluginId: kwin4_effect_maximize isActiveFullScreenEffect: false kwin4_effect_fadingpopups: pluginId: kwin4_effect_fadingpopups isActiveFullScreenEffect: false kwin4_effect_morphingpopups: pluginId: kwin4_effect_morphingpopups isActiveFullScreenEffect: false kwin4_effect_logout: pluginId: kwin4_effect_logout isActiveFullScreenEffect: false kwin4_effect_sessionquit: pluginId: kwin4_effect_sessionquit isActiveFullScreenEffect: false kwin4_effect_frozenapp: pluginId: kwin4_effect_frozenapp isActiveFullScreenEffect: false kwin4_effect_scale: pluginId: kwin4_effect_scale isActiveFullScreenEffect: false kwin4_effect_windowaperture: pluginId: kwin4_effect_windowaperture isActiveFullScreenEffect: false kwin4_effect_dialogparent: pluginId: kwin4_effect_dialogparent isActiveFullScreenEffect: false slidingpopups: slideInDuration: 300 slideOutDuration: 500 slide: duration: 1000 horizontalGap: 45 verticalGap: 20 slideDocks: false slideBackground: true screenshot: desktopgrid: zoomDuration: 600 border: 10 desktopNameAlignment: 0 layoutMode: 0 customLayoutRows: 2 usePresentWindows: true colorpicker: presentwindows: layoutMode: 0 showCaptions: true showIcons: true doNotCloseWindows: true ignoreMinimized: false accuracy: 20 fillGaps: true fadeDuration: 300 showPanel: true leftButtonWindow: 1 rightButtonWindow: 2 middleButtonWindow: 6 leftButtonDesktop: 2 middleButtonDesktop: 0 rightButtonDesktop: 0 highlightwindow: blur: startupfeedback: type: 1 screenedge: kscreen: Loaded Plugins: --------------- kwin5_plugin_krunner kwin5_plugin_nightcolor Available Plugins: ------------------ kwin5_plugin_colord kwin5_plugin_krunner kwin5_plugin_nightcolor
Similar issue, but making Plasma unusable (100% CPU 1 core usage). In my case, all is so slow that moving mouse takes 3 to 4 seconds each time. "kwin_wayland" is the process eating CPU. These are the sub-threads involved (from perf.data): - kms_swrast_dri.so (repeated x 5 times) at 99.3% CPU - libc.so.6 (repeated x 2 times) at 99.3% CPU Operating System: openSUSE Tumbleweed 20230527 KDE Plasma Version: 5.27.5 KDE Frameworks Version: 5.106.0 Qt Version: 5.15.9 Kernel Version: 6.3.2-1-default (64-bit) Graphics Platform: Wayland Processors: 4 × Intel® Core™ i5-6600K CPU @ 3.50GHz Memory: 31.3 GiB of RAM Graphics Processor: NVIDIA GeForce GTX 1050 Ti/PCIe/SSE2
>- kms_swrast_dri.so (repeated x 5 times) at 99.3% CPU swrast or "software rasterizer" is a fallback when drivers are unable to be loaded properly. This indicates a setup issue. Use of the right driver will make a big difference. Wyatt, can you see if this fixes the issue for you too?
(In reply to Nate Graham from comment #5) > >- kms_swrast_dri.so (repeated x 5 times) at 99.3% CPU > > swrast or "software rasterizer" is a fallback when drivers are unable to be > loaded properly. This indicates a setup issue. Use of the right driver will > make a big difference. > In my case, I reinstalled Tumbleweed and G06 Nvidia drivers (instead G05) and it's running "fine" (Steam games are unplayable)
Dear Bug Submitter, This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging If you have already provided the requested information, please mark the bug as REPORTED so that the KDE team knows that the bug is ready to be confirmed. Thank you for helping us make KDE software even better for everyone!
(In reply to Nate Graham from comment #5) > >- kms_swrast_dri.so (repeated x 5 times) at 99.3% CPU > > swrast or "software rasterizer" is a fallback when drivers are unable to be > loaded properly. This indicates a setup issue. Use of the right driver will > make a big difference. > > Wyatt, can you see if this fixes the issue for you too? So Nate, I don't have this card anymore, I gave it to a friend... who also has this problem... I sent him the NEEDSINFO/this bug, but he hasn't really followed up on this. I think it would be useful if there were steps shared about how to identify the issue and how this setup issue might happen. As it stands, working Nvidia Proprietary Fedora drivers under Fedora KDE X11 result in this issue under Fedora KDE Wayland (on at least the two systems this card has been used in).
This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging Thank you for helping us make KDE software even better for everyone!