Hacker News new | past | comments | ask | show | jobs | submit login
BES – OSS Windows software to control per-process CPU usage (yosei.fi)
56 points by olvy0 7 months ago | hide | past | favorite | 9 comments



I wish the FAQ would cover the following.

- Why BES vs lowering process priority.

- Why BES vs lowering CPU clock.

- What algorithm does BES use for when to suspend/unsuspend? (sigma-delta? PWM perhaps? what is the period?)


- Why BES vs the Job Objects APIs which explicitly support this kind of resource limiting


> The thing is, BES needs some privileges to do its job, i.e. suspending and resuming threads that don’t belong to its own process.

Wow so it's turning the target process off and on constantly. I'm surprised that alone doesn't introduce lots of overhead?


One would hope it's using the Windows Job Object APIs instead (e.g. JOBOBJECT_CPU_RATE_CONTROL_INFORMATION).

"Percentage CPU used" already made a lot less sense when Intel SpeedStep arrived, and it makes almost no sense today with mixed P+E cores.


Thats sort of how multitasking works, except its instructed from userspace instead of by the kernel itself.


Linux's cpulimit also does that.

And fundamentally, the kernel scheduler does the same thing because it's a cooperative multitasking OS.


It's a Windows app - if you are worried about overhead, you wouldn't be running Windows in the first place.

But to answer your question, I am sure this has plenty of overhead, but given there are no real alternatives, people still accept it. Better to waste some CPU time that have some totally unresponsive game.


The alternative is called Windows Job Objects, and it allows for limiting CPU and memory usage, among others.

There are numerous libraries and launchers on github; my favorite is [1].

CPU limits are only for Windows 8 or greater though, so for people still on Windows 7 or earlier, then okay, this post is relevant for them.

[1] : https://github.com/lowleveldesign/process-governor


Thanks for this, this seems the proper way to accomplish it




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: