How To Allocating CPU cores On Windows 10

 If you have low-end hardware and want to increase the performance of your favorite programs, allocating CPU cores to it can help.



Windows 10 has many options that you can play around with to get better performance. Windows 10's Processor Affinity and CPU Priority features are some of the most ingenious, and while they're not the silver bullet for an instant performance boost, they will make a difference if you have aging hardware.

Given how sensitive the process is, you should only set Processor Affinity and CPU Priority if you're comfortable with things going south. However, if you want to make your system the best, let's explore how to set Processor Affinity and CPU Priority in Windows 10.

What is Processor Affinity in Windows 10?

Every OS has an underlying scheduling algorithm. Scheduling algorithms are responsible for distributing computer resources to different processes or threads. In Windows 10, there may be hundreds of processes running concurrently.

The CPU cannot handle all of these processes at the same time, so scheduling algorithms manage these processes and assign CPU time based on several factors.

As such, Processor Affinity can be thought of as a user meddling with the scheduler. Usually, the Windows scheduling algorithm decides which processes will run on which CPU cores. If you set Processor Affinity manually, you can force processes or threads to run on any core you like.

Simply put, Processor Affinity lets you assign one or more CPU cores to any process or thread of your choosing. The process or thread for which you set the affinity will only run on the specified core.

However, this will not make the core exclusive to that process only. Windows can still assign a different process to that core. Setting Processor Affinity affects only the processes you select by making them run only on the specified core.

What is CPU Priority in Windows 10?

As we explained above, there can be hundreds of processes or threads competing for CPU time at any given time in Windows 10. To ensure critical processes and threads get priority access to CPU resources, the Windows schedule assigns priority to each running process and thread. in OS.

For example, the Windows scheduling algorithm gives high priority to critical Windows processes such as System and Windows Explorer. If these processes are in the queue, they will gain access to the CPU before the low priority process.

So when you manually set the CPU Priority of a process to high, the Windows schedule will ensure that the process gets priority access to CPU resources.

Lastly, CPU Priority is very different from Processor Affinity. Where the CPU Priority setting of a process tells the scheduler how to treat that process, the Processor Affinity setting locks the process to a specific CPU core/core. With Processor Affinity set, even if a process has high or low priority, it will run on a specific core/core.

Why You Might Want to Assign Programs to Specific CPU Cores

One of the biggest problems modern computing has to deal with is the large number of single-threaded programs. Even in 2021 where most processors are quad-core or higher, some programs only take advantage of one of the many cores available.

This presents a problem for modern OS schedulers: how do you schedule a single-threaded process on a multi-threaded processor without breaking compatibility?

For the most part, modern schedulers efficiently schedule single-threaded processes on modern CPUs. But there are times when old programs break because of poor compatibility. This is where the Processor Affinity setting can help.

Processor Affinity limits processes to execute on a specified CPU core. In the case of older single-threaded programs, you can limit the process to a single CPU core by setting Processor Affinity.

In addition, people with weaker machines can also benefit from setting high priorities for their important tasks. For example, if you are a video editor, you can set your rendering program to high priority before starting video rendering. That way, when you want to make a video, Windows knows to dedicate most of its attention to mashing up your videos.

How to Set CPU Affinity and CPU Priority

To set Processor Affinity and CPU Priority, you will need to open Task Manager and proceed from there.

So, open Task Manager by right-clicking on the Windows 10 taskbar and selecting  Task Manager  . Then navigate to the process for which you want to set the affinity.

Next, right-click on that process and select  Go to details  .

The process you selected will be highlighted in the new pane that appears. Right-click on the highlighted process and select  Set affinity  . The Processor Affinity panel will now appear.

In the Processor Affinity pane, deselect the CPU cores whose processes you don't want. After that, click  Ok  . Processor Affinity will now be set and the process you selected will only run on the selected CPU core.

To set CPU Priority, right click on any process in Task Manager and select  Open details  .

Next, right-click on the highlighted process and click on  Set Priority  .

Now, select a priority from the list that appears. If you want your process to run as fast as it needs to, select  Realtime  .

However, selecting  Realtime  will result in other potentially critical system processes waiting in the queue. This can lead to general system slowdown in the mildest case and complete system failure in the worst case, so be careful when setting processes to Realtime priority.

High priority   , on the other hand, is safer to choose as long as you don't place too many processes on high priority.

The other options on the list, namely  Above normal  ,  Normal  ,  Below normal  , and  Low  , are self-explanatory.

Don't Set Processor Affinity and CPU Priority If You Don't Know What You Are Doing

You should only set Processor Affinity and CPU Priority if you know what you are doing. The performance improvements, while huge in some cases, are not worth the trouble you can run into if something goes wrong. From throttling to random system crashes, setting affinity and priority should only be your last resort.

Processor Affinity and CPU Priority are not the only ways to improve Windows 10 performance. There are a myriad of hardware and software tricks you can use to get performance out of your aging hardware.

Post a Comment

Previous Post Next Post