How to set maximum CPU utilisation %

Moderators: Site Moderators, FAHC Science Team

Post Reply
daxliniere
Posts: 6
Joined: Sun Jan 16, 2022 2:26 pm

How to set maximum CPU utilisation %

Post by daxliniere »

Hey team,
Can someone tell me how to configure F@H on Windows to use a specific maximum amount of CPU, please?
I'm looking for a way to keep my CPU at a minimum utilisation level at all times and figured that F@H would be an ethical way to achieve that.

Thank you in advance,
Dax.
JimboPalmer
Posts: 2573
Joined: Mon Feb 16, 2009 4:12 am
Location: Greenwood MS USA

Re: How to set maximum CPU utilisation %

Post by JimboPalmer »

Welcome to Folding@Home!

In FAHControl (also called Advanced Control) you can select the number of threads to fold on. (F@H calls them CPUs)

There will be a button named Configure, then a tab called Slots. Choose cpu and press Edit

You can choose the number of threads you want to use, or set it to -1, which lets the software decide.

Then save
Tsar of all the Rushers
I tried to remain childlike, all I achieved was childish.
A friend to those who want no friends
daxliniere
Posts: 6
Joined: Sun Jan 16, 2022 2:26 pm

Re: How to set maximum CPU utilisation %

Post by daxliniere »

Thanks Jimbo. I had changed it from -1 to 1, but it's still using a lot of CPU, enough to get the fans moving.
gunnarre
Posts: 567
Joined: Sun May 24, 2020 7:23 pm
Location: Norway

Re: How to set maximum CPU utilisation %

Post by gunnarre »

What is your CPU and type of computer? Some modern CPUs will typically boost to very high frequencies on single core loads, enough to get the fans of the computer working. Especially vector math like AVX_2 will use some power even when working on one CPU core.

If you have a newish Intel CPU with "E cores" (power efficient cores) it might be beneficial to use a tool which limits Folding@Home to one or more of these "E cores" rather than the "P cores" (performance cores). Some people have reported that limiting to the E cores gives a nice Folding@Home production without giving high power usage.

If you can post the first part of your log that shows your CPU etc. that might be helpful, e.g. from my system

Code: Select all

22:37:50:******************************* System ********************************
22:37:50:        CPU: Intel(R) Core(TM) i5-4278U CPU @ 2.60GHz
22:37:50:     CPU ID: GenuineIntel Family 6 Model 69 Stepping 1
22:37:50:       CPUs: 4
22:37:50:     Memory: 8.00GiB
22:37:50:Free Memory: 4.78GiB
22:37:50:    Threads: POSIX_THREADS
22:37:50: OS Version: 10.14
22:37:50:Has Battery: true
22:37:50: On Battery: false
22:37:50: UTC Offset: 1
22:37:50:        PID: 72
22:37:50:        CWD: /Library/Application Support/FAHClient
22:37:50:         OS: Darwin 18.7.0 x86_64
22:37:50:    OS Arch: AMD64
22:37:50:       GPUs: 0
22:37:50:       CUDA: Not detected: Failed to open dynamic library 'libcuda.dylib':
22:37:50:             dlopen(libcuda.dylib, 1): image not found
22:37:50:     OpenCL: Not detected: Failed to open dynamic library 'libOpenCL.dylib':
22:37:50:             dlopen(libOpenCL.dylib, 1): image not found
22:37:50:***********************************************************************
Image
Online: GTX 1660 Super, GTX 1080, GTX 1050 Ti 4G OC, RX580 + occasional CPU folding in the cold.
Offline: Radeon HD 7770, GTX 960, GTX 950
daxliniere
Posts: 6
Joined: Sun Jan 16, 2022 2:26 pm

Re: How to set maximum CPU utilisation %

Post by daxliniere »

Hey Gunnarre, thanks so much for your reply. CPU is Intel i7-10750H @ 2.6GHz (hex-core, hyperthreaded).

To tell you the full story, I have a new ASUS laptop and there's a lot of coil whine ('chirping' noises) coming from the CPU when load is low. When the CPU is above about 15%, it's completely silent.
Windows' power mgmt is ignoring the Minimum Process State value; even tested at 40%, Task Manager shows around 5%.

If I can force a process to use CPU in the background, it'll solve this issue and F@H seems like a great ethical solution. (Otherwise it's CPU mining cryptocurrency...)
JimboPalmer
Posts: 2573
Joined: Mon Feb 16, 2009 4:12 am
Location: Greenwood MS USA

Re: How to set maximum CPU utilisation %

Post by JimboPalmer »

https://ark.intel.com/content/www/us/en ... 0-ghz.html

Your CPU has 6 cores and 12 threads
As far F@H goes, one thread is the least you can do, third party 'tuning' apps may allow you to lower power and frequency, I confess I just let my laptops be loud.

https://www.msi.com/Landing/afterburner/graphics-cards
I think of this as a GPU tuner, but it can tune CPUs as well.
Tsar of all the Rushers
I tried to remain childlike, all I achieved was childish.
A friend to those who want no friends
daxliniere
Posts: 6
Joined: Sun Jan 16, 2022 2:26 pm

Re: How to set maximum CPU utilisation %

Post by daxliniere »

Okay, thanks Jimbo. I was hoping there would be a setting I could apply to set a specific limit.

I tried Afterburner on your suggestion, but couldn't find any CPU-related controls, only GPU stuff.

Thanks again!
MeeLee
Posts: 1375
Joined: Tue Feb 19, 2019 10:16 pm

Re: How to set maximum CPU utilisation %

Post by MeeLee »

I think Fah does best with more cores at a lower frequency (disable turbo boost), rather than fewer cores at a higher frequency.
You can also disable hyperthreading. That will allow more L-Cache per core.

I don't have experience with this CPU, but I do know that there's a relation between power consumption and heat, and thus heat and core frequency.
Your CPU is 5Ghz boost, and 2,60Ghz base frequency.
In most cases intel's base frequency is a compromise between performance and power consumption.
If you think with turbo boost and HT disabled, the CPU still runs too hot, you may be able to get a few degrees off by lowering the performance to 2Ghz, but anything below 1,6Ghz usually is not really making the CPU any cooler anymore, or changes anything on power consumption.
At least, on my 9th gen cpus.

A third thing you can do is lower ram speeds by disabling XMP. Usually that means lowering from 2,9Ghz or 2,333Ghz to 2,1Ghz, and also lower the RAM sticks from 3V to 1,5V or lower.
The impact should be less than a 10% reduction on PPD.
You could possibly lower the voltage further by a bit, both CPU and GPU, but could run into stability issues, if voltage is lowered too much.

Some motherboards have a profile where you can load 'eco' setting, that somewhat limit power consumption.

If your laptop doesn't support CPU and RAM voltage or frequency modifications, you can always change the maximum CPU performance from 100% to 1% (or anything in between), in Windows power management.
It should somewhat disable turbo boost as well, and is the easiest/quickest thing you can do.

Play around with the settings that work best for you, in terms of power consumption, heat, and performance.
daxliniere
Posts: 6
Joined: Sun Jan 16, 2022 2:26 pm

Re: How to set maximum CPU utilisation %

Post by daxliniere »

Hey MeeLee,
Thanks for taking the time to reply.
I think you may have missed why I'm asking for this. My laptop emits coil whine (chirping) when CPU is at low utilisation as it is put into a low power state. If I were to underclock my system, I would be affecting everything, at which point I could just buy an old computer without the noise. ;)

All the best,
Dax.
gunnarre
Posts: 567
Joined: Sun May 24, 2020 7:23 pm
Location: Norway

Re: How to set maximum CPU utilisation %

Post by gunnarre »

So your problem here is that you want some minimum CPU utilisation, but your CPU also boosts too high even on a single core when you load it with a FAH job. There is a little documented F@H setting called "cpu-usage" that you can set in the "Extra slot options" for the CPU slot. You can set this to a value between 1 and 100, and see if that does what you want. Warning: This is an outdated and very inefficient way to limit CPU usage, and reducing the CPU power settings in Windows/BIOS are a better way to to it. If you fail to complete the work units within the "Timeout" time, you shouldn't be folding at all. Folding@Home projects are time critical - one folder relies on the work done by a previous folder in a sort of relay race. If you don't return the work unit within the Timeout time, that leads to the project being delayed and unnecesary duplication of effort. If that's the case you should consider using something like BOINC for this, or just use another tool to load the CPU to get rid of the coil whine.
Image
Online: GTX 1660 Super, GTX 1080, GTX 1050 Ti 4G OC, RX580 + occasional CPU folding in the cold.
Offline: Radeon HD 7770, GTX 960, GTX 950
daxliniere
Posts: 6
Joined: Sun Jan 16, 2022 2:26 pm

Re: How to set maximum CPU utilisation %

Post by daxliniere »

Thanks again, Gunnarre. Unfortunately there are no settings in the BIOS for C-cstates, in fact, there are very few options at all, mostly just disk stuff. Can't even disable on-board sound if I wanted to.
I had originally posted this in a couple overclocking and benchmarking subreddits, but there doesn't seem to be a tool to load it down to a specific amount (or, rather, keep it at a minimum load). Some suggests there were F@H and mining Raptoreum.

Thanks every and all the best,
Dax.
Neil-B
Posts: 2027
Joined: Sun Mar 22, 2020 5:52 pm
Hardware configuration: 1: 2x Xeon E5-2697v3@2.60GHz, 512GB DDR4 LRDIMM, SSD Raid, Win10 Ent 20H2, Quadro K420 1GB, FAH 7.6.21
2: Xeon E3-1505Mv5@2.80GHz, 32GB DDR4, NVME, Win10 Pro 20H2, Quadro M1000M 2GB, FAH 7.6.21 (actually have two of these)
3: i7-960@3.20GHz, 12GB DDR3, SSD, Win10 Pro 20H2, GTX 750Ti 2GB, GTX 1080Ti 11GB, FAH 7.6.21
Location: UK

Re: How to set maximum CPU utilisation %

Post by Neil-B »

Many laptop vendors give few if any options for adjusting the cpu voltages/power/clocks/etc. I'm afraid :(
2x Xeon E5-2697v3, 512GB DDR4 LRDIMM, SSD Raid, W10-Ent, Quadro K420
Xeon E3-1505Mv5, 32GB DDR4, NVME, W10-Pro, Quadro M1000M
i7-960, 12GB DDR3, SSD, W10-Pro, GTX1080Ti
i9-10850K, 64GB DDR4, NVME, W11-Pro, RTX3070

(Green/Bold = Active)
MeeLee
Posts: 1375
Joined: Tue Feb 19, 2019 10:16 pm

Re: How to set maximum CPU utilisation %

Post by MeeLee »

coil whine shouldn't happen when a CPU is using less than 80% of max power levels.
It usually comes when the CPU is using 100% of the power the VRAM, and has wait times, where the capacitors recharge.
The charge/discharge of the capacitors is what causes 'coil whine', and isn't related to any actual coils.
By lowering the maximum power draw (eg: disable turbo boost), you essentially prevent the CPU from utilizing all power of the caps, and thus should lower coil whine.
gunnarre
Posts: 567
Joined: Sun May 24, 2020 7:23 pm
Location: Norway

Re: How to set maximum CPU utilisation %

Post by gunnarre »

I know that some power supply circuits start making an audible whine if power draw is very low. In the case I discovered it wasn't capacitors in the CPU voltage regulators, but the 5V voltage supply circuits (used by e.g. USB power).
Image
Online: GTX 1660 Super, GTX 1080, GTX 1050 Ti 4G OC, RX580 + occasional CPU folding in the cold.
Offline: Radeon HD 7770, GTX 960, GTX 950
Post Reply