Improve desktop animations by raising GPU min frequency #714
Replies: 2 comments 10 replies
-
Hi! It's true that waking up from deep idle takes a bit longer than ideal. This is something that should (hopefully) gradually improve in future releases, but as far as I know we don't have a silver bullet solution in the works. However, I don't think that locking clocks is a thing that can be applied unconditionally. For many usecases, the power draw at idle is a much more important metric than animation choppiness. If a certain distribution or compositor or whatever wants to try it, go for it! The tools are all there. Just ensure your users are aware of the tradeoff. There may be another thing to try. The chopiness comes from (a) waking up the GPU/etc (sometimes, if it went into a deep idle mode) and (b) warming up the GPU to handle the work. The second part is usually done dynamically, depending on the workload, so it might take a bit for it reach the clock levels necessary. Let me know if anyone wants to give this a try and I can share some magic commands to see if there's a tangible benefit. These wouldn't be production worthy, but if the benefit is there we can work together to get something that is. |
Beta Was this translation helpful? Give feedback.
-
Thanks for looking into this, OP. It's good that you're trying to sort this out. Your methods might need some refinement, though.
Does it, though?
This is a good sign that the clock speeds are related to the problem. It is NOT a sign that you should implement higher clock speeds for all of your users. This is like This is not the way to fix cars... or computers or anything else 😆 |
Beta Was this translation helpful? Give feedback.
-
👤 Reporter
Hi, I'm the current maintainer of
optimus-manager
.I have observed an idea I wanted to share with you. Otherwise I may implement it on
optimus-manager
itself.🔍 Description
By default the NVIDIA GPU lowers its speed to its lowest when it isn't used.
But that has a drawback on window managers that use composition. Animations after a period of inactivity are presented kind of choppy.
But if I set the minimum clocks to the 0.5 of the max with:
sudo nvidia-smi --id=0 --lock-gpu-clocks=892,1785
Suddenly all choppiness is gone.
🧫 Reproducing
I have an Nvidia GeForce 1650 on an Optimus laptop: Lenovo IdeaPad Gaming 3 15IMH05.
I'm using Plasma with Kwin, having as (Desktop Effects -> Window Open/Close Animation -> Glide).
You can see the difference more when opening or closing windows that have complex drawings on them, like on (Inkscape -> Help -> About Inkscape).
📊 Metrics
Before running
nvidia-smi
Plasma reports 2:45 minutes of battery, and after that 2:40. So the power usage difference isn't that much.If I go as far as 0.6, then I get 2:30. So 0.5 seems just the sweet spot.
🪛 Commands
Other useful commands are:
nvidia-smi --id=0 --query-supported-clocks=graphics --format=csv
nvidia-smi --id=0 --query-gpu=clocks.current.graphics,clocks.current.sm,clocks.current.memory,clocks.current.video --format=csv
Beta Was this translation helpful? Give feedback.
All reactions