Often, you might find yourself wondering why Windows performance is bad. Often the reason is certain app which is maxing out CPU load.
Thankfully, Windows 10 includes a feature which allows you to assign specific CPU cores to certain apps, which in certain cases can help improving overall Windows performance. This is called process affinity / processor affinity / cpu affinity.
Processor affinity comes in handy when you wish to run an application for a certain purpose, but you don’t want it to overload your processor.
In this tutorial, we will show you how you can improve Windows performance by changing cpu affinity. Additionally, we will guide you through the process of how to change the CPU priority to prefer Windows foreground apps.
Designating cores for a particular app
Before explaining the simple procedure, keep in mind that the available cores for each app are all the cores that your CPU has. So, if your device is running with a 8-core cpu, Windows allows apps to use all of them at any given time.
The process of assigning specific cores to applications (to set processor affinity) for a program or selected processes is fairly easy and can be done using Task Manager. When you try to do this, make sure you are using the Administrator account on your device or that your account has Administrative privileges.
Here is what you must do to set process affinity:
- Open Task Manager (right-click on the Taskbar and select “Task Manager” or search for “task manager” in the Start search menu)
- Choose “More details” at the bottom-left corner
- Choose the app (that is already running) for which you wish to designate cores
- Right-click on the app and select “Go to details” to jump to the respective Windows task
- In the new window, right-click again on the app and click on “Set affinity”
- In the “Processor affinity” window, choose which cores you would like this app to use when running to change the affinity setting
- Click “OK” to switch the settings to the new values
Note: If you restart your computer or the app, the change for process affinity will revert and the app in question will again use all available CPU cores which ist the standard setting.
Set or change CPU priority to prefer Windows background apps or Programs
On top of the above feature which allows you to designate a specific number of cores for each application, you can also opt for overall CPU scheduling.
This means that Windows gives you the best possible performance while using programs or background apps.
You can make this adjustment easily in the Control Panel:
- Hit the Windows key + R to open “Run” and type “sysdm.cpl” then hit Enter
- In the “System Properties” window that opens, click on the “Advanced” tab and under “Performance” click on “Settings”
- In the “Performance Options” window click on the “Advanced” tab again and you will see a section called “Processor scheduling”
In this section, there are two settings from which you can choose:
- Adjust for best performance of Programs
- Adjust for best performance of Background services
Using this feature, you can set up Windows to know how to distribute or allocate the available resources to best perform certain tasks. For example, if you are using your PC as a Server you can select the “Adjust for best performance of Background services”. Windows will then share processor resources equally between background and foreground programs.