DESCRIPTION I am on Fedora 44 KDE, running Plasma 6.7, KDE Frameworks 6.27.0, Qt 6.11.1, kernel 7.0.12-201, using Wayland. I have an Intel Core Ultra 7 265H and an NVIDIA GeForce RTX 5070 GPU on a Lenovo Thinkpad, and have the latest Mesa and proprietary NVIDIA drivers (595.80, from RPM Fusion). (This is a dual GPU setup.) Before, under Plasma 6.6.5, my idle power usage was about 3-4 W, and browsing on a regular website (not social media or YouTube) with Vivaldi was about 6-7 W. (This was all while on Power Saver mode, at 5% screen brightness.) I upgraded to Plasma 6.7, and now my idle power usage is 12-14 W, and writing this post was 14-16 W. When I check System Monitor under Plasma 6.7, Plasma Background Services uses about 2-5% of my CPU, with nearly all of that from kwin_wayland. (When I downgrade to Plasma 6.6.4 and check, with System Monitor and this browser open, the CPU usage is far smaller from kwin_wayland, around 0.1-0.3%.) When I use the command "sudo dnf downgrade plasma-desktop", my desktop is downgraded to 6.6.4 and my KDE apps to 25.12.3, and my battery life returns to normal. When I upgrade again to Plasma 6.7, using the Terminal or Discover, the high battery consumption returns. STEPS TO REPRODUCE 1. Upgrade from Plasma 6.6.4 or Plasma 6.6.5 to Plasma 6.7 (either through Discover or the Terminal) OBSERVED RESULT CPU usage is high, and battery life is severly shortened. When booting up, the startup sound also is slower to play after loading the desktop than under previous Plasma versions. EXPECTED RESULT CPU usage and battery life are comparable to Plasma 6.6.4 and 6.6.5. SOFTWARE/OS VERSIONS Operating System (available in the Info Center app, or by running `kinfo` in a terminal window): KDE Plasma Version: 6.7 KDE Frameworks Version: 6.27.0 Qt Version: 6.11.1 ADDITIONAL INFORMATION Also posted in the Ask Fedora forums at https://discussion.fedoraproject.org/t/battery-life-consumption-skyrockets-after-upgrading-to-plasma-6-7/194170
Can you check with hotspot (https://github.com/KDAB/hotspot) where that CPU usage comes from? A screenshot of the flamegraph should be enough, if there's something obvious. Most likely that kind of power difference doesn't come from such a small amount of CPU usage though. Is your GPU perhaps not automatically going into the low power mode anymore? You can check its power state with > cat /sys/class/drm/card0/device/power_state (card0 may not be right, you can use drm_info to find out if you need card0 or card1)
(In reply to Zamundaaa from comment #1) > Can you check with hotspot (https://github.com/KDAB/hotspot) where that CPU > usage comes from? A screenshot of the flamegraph should be enough, if > there's something obvious. > > Most likely that kind of power difference doesn't come from such a small > amount of CPU usage though. Is your GPU perhaps not automatically going into > the low power mode anymore? > > You can check its power state with > > cat /sys/class/drm/card0/device/power_state > (card0 may not be right, you can use drm_info to find out if you need card0 > or card1) Checking the power state, card 0 (Intel Arrow Lake-P Arc Pro 130T/140T) says "D3cold," while card 1 (NVIDIA GeForce RTX 5070 Max-Q/Mobile) says "D0." I'm having trouble using hotspot. I downloaded the AppImage from the link you sent and tried to Profile System with Elevated Privileges and Off-CPU Profiling. I record it for a minute, and the output says this: $ /usr/bin/pkexec /usr/bin/perf record -o /home/devin/Downloads/perf.data --call-graph dwarf,8192 --event cycles --switch-events --event sched:sched_switch --aio -z --sample-cpu --mmap-pages 16M --all-cpus --control fifo:/run/user/1000/hotspot-8342-3d50cd89-f2d8-4223-8abc-97c639a226ce-perf-control.fifo,/run/user/1000/hotspot-8342-3d50cd89-f2d8-4223-8abc-97c639a226ce-perf-ack.fifo [ perf record: Woken up 173 times to write data ] Couldn't decompress data 0x5b2088 [0x14bc]: failed to process type: 83 [Operation not permitted] [ perf record: Captured and wrote 47.324 MB /home/devin/Downloads/perf.data, compressed (original 1461.994 MB, ratio is 35.121) ] recording finished after 1min 01.153s I'm not sure how to fix this, as the Github website didn't have any information that would help me figure this out.
ok, with those power states, we don't need to look at hotspot. Your dedicated GPU is used for the internal display. Please attach the output of drm_info.
Created attachment 193463 [details] drm_info Here are the drm_info results.
Hello, I also saw the same power state status for Plasma 6.6.4 (D3cold for Intel, D0 for NVIDIA), for what it's worth. It seems like my computer isn't using my Intel iGPU, which is odd. I was also able to get results from 'perf report' from both 6.6.4 and 6.7, if you're interested in those results.
Created attachment 193468 [details] Pictures from "perf record" OK, I think I've more clearly isolated the bug. I was writing this post and checking my power usage with Info Center - Energy, and found it was normal for me (5-6 W). So I decided to watch a youtube video, and that was normal power usage too (9-11 W). Then I closed all my programs except for Info Center - Energy. And that's when the power spikes started again, going at about 15-18 W, constantly. So I ran "perf record" for 1 minute and checked the results, which I've attached here. (I'll attach the other pictures of the results. Usually, when I close all windows and only leave Info Center - Energy running, the computer goes down to 3-4 W, not huge. But according to "perf report," nvidia-powerd is using a ton of energy when all my programs are closed, and the power usage greatly increases. According to my computer, switcheroo-control.service is always running, and the result of "switcheroooctl" says that my Intel iGPU is set to Default while my NVIDIA one is not default. (Not sure what that means with the power state results I saw earlier.)
Created attachment 193469 [details] Perf report - idle usage from cpu_lowpower
Created attachment 193470 [details] Picture from "perf report" - idle power for cpu_atom_cycles
Created attachment 193471 [details] Picture from "perf report" while programs open - cpu_core_cycles And here is the "perf report" for cpu_core cycles for Plasma 6.7 when I have various programs open such as Vivaldi and Konsole. The power usage is far less. It seems like, if I'm reading this right, my Intel GPU is used when I have different programs running, but once I close them all, it switches everything to rendering to the NVIDIA GPU and uses way more power. Is that correct?
Created attachment 193474 [details] "perf report" after awaking from sleep. Another thing. I put my computer to sleep for 20 minutes, then woke it up, which it did fine. But then it started using a ton of energy (15-18W) constantly no matter what I do, no matter what program I run. "perf report" for my cpu_core_cycles says that nvidia-powerd is now using a lot of power, alongside kwin_wayland. See attached picture.
(In reply to devinobannon from comment #4) > Created attachment 193463 [details] > drm_info > > Here are the drm_info results. The important parts are cut off. You can get the full output by piping it into a file, like so: drm_info > info.log > nvidia-powerd is using a ton of energy when all my programs are closed, and the power usage greatly increases Sounds like that daemon might simply be buggy. Can you try stopping it?
Created attachment 193776 [details] drm_info log Apologies, I'm still new to linux. I did what you said regarding the drm_info log, and this should be the full log you requested.
Also, regarding nvidia-powerd: when I stopped it the service (using "systemctl stop nvidia-powerd.service"), the power usage (on idle, web browsing, etc.) got much more normal. When I started it again ("systemctl start nvidia-powerd.service"), then the power usage jumped again. Then when I stopped it again, things were normal again.
Also, I just updated to kernel 7.0.13-200.fc44.x86_64 (64-bit), and Plasma 6.7.1, and I'm still seeing the same issues with the nvidia-powerd.service. When I start up nvidia-powerd.service, it has the same high power usage issues, but when I stop it, the power usage goes back to normal again.
Created attachment 193780 [details] Core cycles after waking from sleep OK, now I found where kwin is eating my CPU. I have killed the troublesome nvidia power daemon mentioned earlier, so it is not active. I put my computer to sleep. Then when I woke it up, it started using a lot of power 18W constantly for at least 20 minutes. The results from "perf record" are above, showing kwin using a lot of CPU. Eventually, the power usage returns to more normal levels, but not before taking nearly 8-10% of my battery in the process.
Hmm, drm_info shows that the Nvidia GPU doesn't even have any connectors. If you put KWIN_DRM_DEVICES=/dev/dri/card1 into /etc/environment and reboot, does that change anything? If it doesn't help, you can also try KWIN_DISABLE_VULKAN=1
Created attachment 193880 [details] drm_info from Plasma 6.6.4 I've attached the drm_info log from when I was under Plasma 6.6.4, in case there are any differences. When I tried to make KWIN render under card1 (which is the Intel iGPU, according to drm_info), it made the energy consumption increase, weirdly enough. Trying the second environment variable (DISABLE_VULKAN) seems to make everything work normal (boot, wake from sleep, etc.). Though for some reason, under Plasma 6.6.4, the boot up sound plays immediately upon login, while under Plasma 6.7 it plays late (several seconds after login), whether Vulkan is disabled for kwin or not. Not sure if that indicates anything. I'll try gaming under the Vulkan being disabled for kwin and see if it affects anything.
OK, I tried gaming with Steam (playing the Talos Principle 2 with Proton), and everything seems normal, as far as I can tell (and testing it for only 2 minutes or so).
Alright, there's a chance this has the same underlying cause as bug 521742. If you set KWIN_COMPOSE=O2ES without any other environment variable, do things also work fine for you?
Hello, No, unfortunately, the problem returns when I replace KWIN_DISABLE_VULKAN=1 with KWIN_COMPOSE=O2ES. The power usage goes up again to 12-15W when idle, and even higher when I'm doing tasks. (I also tried both environment variables on at the same time, and it didn't seem to matter that much whether the KWIN_COMPOSE variable was there or not.) I'm on Plasma 6.7.2 and kernel 7.1.3, so the bug wasn't fixed by either update.
Okay, then it sounds like nvidia-powerd is simply doing bad things once KWin (or probably any other app) uses Vulkan... Please report that to Nvidia. In the meantime, disabling KWin's Vulkan usage shouldn't pose any big problems as workaround.
OK, thanks for your help.