Question How can I reduce my CPU usage but keep the same amount of FPS?

Sep 8, 2024
3
0
10
When I play games, my FPS is fine, but my CPU usage reaches around 95-100, which causes massive keyboard delay and keyboard stick (not physically), and its annoying. I boiled down the issue to the CPU usage. When I try to reduce cpu usage (or atleast successfully do,) FPS is sacrificed, which is extremely annoying.
Now I am wondering, how can I reduce CPU usage from a certain application without the FPS dropping. I feel like I have been running around circles for the past 2 weeks / 1 month.
 
Space magic! ;)

Ok, so to be a bit more serious, frame rate depends on both CPU and GPU. If the GPU is faster than the CPU, then the GPU load will not reach 100% before the CPU does. Slowing down your GPU so it doesn't consume so much isn't really what you are looking for ("these are not the droids you are after"...a form of space magic). Most of what you are talking about requires either a faster CPU, or rewriting the software which is driving the CPU.

Sometimes delays are just from using the disk for swapping memory when you don't have enough RAM. Having lots of RAM can make things smoother even when the load is the same if compared to having even a slight bit of swap space being active. These days most computer games can avoid swap with about 32 GB of RAM, but it varies (some might not need more than 16 GB).

There is another phenomenon which occurs when everything saturated in the CPU, but when otherwise there is no shortage of resources (e.g., you have lots of RAM, any disk access is really fast, so on). On a desktop PC architecture this is really rare, but there is something called IRQ starvation (interrupt request starvation). Whenever hardware needs a driver to service it, e.g., after a network adapter has read data, the scheduler is notified that this device needs attention. For hardware (versus something purely in software) this means you need a physical wire to send that notification. There are different mechanisms for this, but for example, on Intel there is a programmable I/O APIC (Asynchronous Programmable Interrupt Controller); this APIC can be told to send the IRQ to any CPU core. At some point, if a lot of other hardware devices are saturated with activity (including a mouse or keyboard if running in interrupt mode), then the devices begin fighting each other for access. The scheduler has to decide which one gets priority, and maybe your mouse has a lower priority than the hard drive.

I do not think you have reached IRQ starvation. I think the software from your game or other program simply is not optimized. If it were, then probably the frame rate and other issues would "smoothly" become too slow, and you wouldn't be thinking of it as "stuck". I think there is nothing you can do about this without a faster CPU (and/or perhaps RAM). It depends on the combination of the hardware, o/s, whatever else is running, what peripherals you have (e.g., a mouse is external, but won't use much in the way of resources, but a USB hard drive could be a massive load), and the software design of the specific program you see this in. If it is a game, and if other players are using more or less faster CPU and/or more RAM, then I doubt anyone would want to optimize for your case. You're left with a CPU and/or RAM upgrade.

Perhaps if you gave system specs and what is running, then you might have other people provide suggestions of what they think of that hardware for that situation.