Processor Affinity

How to Set the Processor Affinity for a Application in Vista

information   Information
By default, Vista set processes to run on all available processors (CPUs). If you have multiple processors or a multi-core processor, then you can use Process Affinity to control what processor(s) a application runs on. This will show you how to change the Processor Affinity for an application (process).

WHY:

Like setting the CPU Priority, you can set the Processor Affinity to have a application (Ex: Anti-Spyware scan) to use only one CPU while you have another application (Ex: Internet Explorer) running on just the other CPU to allow maximum usage of the CPU assigned to each application.
Note   Note

  • If the installed application supports Symmetric Multiprocessing (SMP) or HyperThreading (HT), then Vista will help automatically adjust the application's usage of each processor for the best performance. You will not gain much, if anything, from manually changing the processor affinity for these applications.
  • The Processor Affinity setting you make for a application will only last as long as the application is open. If you close the application or restart the computer, then the Processor Affinity will return to the default of using all CPUs automatically for that application.
Tip   Tip

COMMON PROBLEM:

You may discover that certain older applications, that are not multiprocessor (SMP or HT) aware, ran fine on systems with one single core CPU are now not running properly on multiple processors or a multi-core processor. For example, your application may suddenly begin maxing out the CPU usage at 100 percent, appearing to lock up.The Processor Affinity setting allows you to work around such problems by configuring older applications to use only one of the cores instead.
warning   Warning
It is recommmended to not change the process affinity on Vista system file processes to avoid potential problems. Only change the process affinity on application processes instead to be safe.




Here's How:
1. Open Task Manager.​
NOTE: Right click on the taskbar and click Task Manager, or press Ctrl+Shift+Esc.​
2. Click on the Processes tab. (See screenshot below step 6)​
3. Click on the Show processes from all users button.​
4. Click on Continue in the UAC prompt.​
5. Right click the process (application) you want to change the processor affinity on.​
6. Click on Set Affinity.​
Task_Manager.jpg

7. Check the CPU(s) that you want the process to run on. (See screenshot below step 8)​
NOTE: If the process (application) does not support SMP or HT, then you may only want to have one CPU checked. If the process (application) does support SMP or HT, then you will most likely not gain any performance by not having all available CPUs checked. See the NOTE and COMMON PROBLEM sections at the top of the tutorial for more on this.​
8. Click on OK.​
Processor_Affinity.jpg

9. Close Task Manager when done.​
NOTE: If you need to change the process affinity on another application, then just repeat these steps for it.​
That's it,
Shawn



 

Attachments

  • Performance.png
    Performance.png
    12.1 KB · Views: 505
Last edited:
Thanks for the info.
Will these affinities actually stick (meaning be the same next time I restart)? Same question would interest me for priorities as well...
Cheers
Grojor
 

My Computer

Hi Grojor,

Welcome to Vista Forums. :party:

Sorry, the settings will only last for as long as the application is open. Once closed, or computer restarted, they go back to the default settings. :(

I have heard that some programs that are multi-core or multi-CPU aware may have settings in the program itself that will remain though. I could not tell you of any off the top of my head though.

Shawn
 

My Computers

System One System Two

  • Operating System
    Windows 10 Pro 64-bit
    Manufacturer/Model
    Custom
    CPU
    Intel i7-8700K 5 GHz
    Motherboard
    ASUS ROG Maximus XI Formula Z390
    Memory
    64 GB (4x16GB) G.SKILL TridentZ RGB DDR4 3600 MHz (F4-3600C18D-32GTZR)
    Graphics card(s)
    ASUS ROG-STRIX-GTX1080TI-O11G-GAMING
    Sound Card
    Integrated Digital Audio (S/PDIF)
    Monitor(s) Displays
    2 x Samsung Odyssey G7 27"
    Screen Resolution
    2560x1440
    Hard Drives
    1TB Samsung 990 PRO M.2, 4TB Samsung 990 PRO PRO M.2, 8TB WD MyCloudEX2Ultra NAS
    PSU
    Seasonic Prime Titanium 850W
    Case
    Thermaltake Core P3
    Cooling
    Corsair Hydro H115i
    Mouse
    Logitech MX Master 3
    Keyboard
    Logitech wireless K800
    Internet Speed
    1 Gb/s Download and 35 Mb/s Upload
    Other Info
    Logitech Z625 speaker system, Logitech BRIO 4K Pro webcam, HP Color LaserJet Pro MFP M477fdn, APC SMART-UPS RT 1000 XL - SURT1000XLI, Galaxy S23 Plus phone
  • Operating System
    Windows 10 Pro
    Manufacturer/Model
    HP Envy Y0F94AV
    CPU
    i7-7500U @ 2.70 GHz
    Memory
    16 GB DDR4-2133
    Sound Card
    Conexant ISST Audio
    Monitor(s) Displays
    17.3" UHD IPS touch
    Screen Resolution
    3480 x 2160
    Hard Drives
    512 GB M.2 SSD
Hello, I'm new and I'd just like to say your threads and guides are really good, very helpful. One question about setting the process affinity...

Can it be, for example set to high or real time everytime the application/.exe runs?

Thanks.
 

My Computer

Hello Carlos,

Sorry but no, the settings will only last for as long as the application is open. Once closed, or the computer is restarted, they go back to the default settings. :(

I have heard that some programs that are multi-core or multi-CPU aware may have settings in the program itself that will remain set though. I could not tell you of any off the top of my head though.

Shawn
 

My Computers

System One System Two

  • Operating System
    Windows 10 Pro 64-bit
    Manufacturer/Model
    Custom
    CPU
    Intel i7-8700K 5 GHz
    Motherboard
    ASUS ROG Maximus XI Formula Z390
    Memory
    64 GB (4x16GB) G.SKILL TridentZ RGB DDR4 3600 MHz (F4-3600C18D-32GTZR)
    Graphics card(s)
    ASUS ROG-STRIX-GTX1080TI-O11G-GAMING
    Sound Card
    Integrated Digital Audio (S/PDIF)
    Monitor(s) Displays
    2 x Samsung Odyssey G7 27"
    Screen Resolution
    2560x1440
    Hard Drives
    1TB Samsung 990 PRO M.2, 4TB Samsung 990 PRO PRO M.2, 8TB WD MyCloudEX2Ultra NAS
    PSU
    Seasonic Prime Titanium 850W
    Case
    Thermaltake Core P3
    Cooling
    Corsair Hydro H115i
    Mouse
    Logitech MX Master 3
    Keyboard
    Logitech wireless K800
    Internet Speed
    1 Gb/s Download and 35 Mb/s Upload
    Other Info
    Logitech Z625 speaker system, Logitech BRIO 4K Pro webcam, HP Color LaserJet Pro MFP M477fdn, APC SMART-UPS RT 1000 XL - SURT1000XLI, Galaxy S23 Plus phone
  • Operating System
    Windows 10 Pro
    Manufacturer/Model
    HP Envy Y0F94AV
    CPU
    i7-7500U @ 2.70 GHz
    Memory
    16 GB DDR4-2133
    Sound Card
    Conexant ISST Audio
    Monitor(s) Displays
    17.3" UHD IPS touch
    Screen Resolution
    3480 x 2160
    Hard Drives
    512 GB M.2 SSD
Back
Top