Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Set AFFINITY of a game

05 Oct 2015   #1
beret21

Windows 7 Ultimate x64
 
 
Set AFFINITY of a game

I have searched a lot but couldn't find the command to set the affinity of a process that is already running.

All the examples i came across are to start a program with desired affinity but none showed how to change the affinity of a program already running.

For example i have notepad.exe running and i want it to use only core 2 and three. What cmd command can be used for that


My System SpecsSystem Spec
.
06 Oct 2015   #2
Alejandro85

Windows 7 Ultimate x64
 
 

In task manager, in the processes tab search the process. The context menu contains a "set affinity" option that allows to chose which CPUs will run that program.
My System SpecsSystem Spec
06 Oct 2015   #3
RoasterMen

Windows 10 Pro 64-bit
 
 

^ Normal way.

But he asked for a command prompt parameters so he wouldn't do that everytime.

Try these:

Set affinity with start /AFFINITY command on Windows 7 - Stack Overflow

or

Start an Application Assigned to a Specific CPU in Windows 7, 8, or Vista
My System SpecsSystem Spec
.

07 Oct 2015   #4
beret21

Windows 7 Ultimate x64
 
 

Quote   Quote: Originally Posted by RoasterMen View Post
^ Normal way.

But he asked for a command prompt parameters so he wouldn't do that everytime.

Try these:

Set affinity with start /AFFINITY command on Windows 7 - Stack Overflow

or

Start an Application Assigned to a Specific CPU in Windows 7, 8, or Vista

Thanks for the link but again these are to start a program with defined affinity not to set the affinity of a program thats already running
My System SpecsSystem Spec
07 Oct 2015   #5
RoasterMen

Windows 10 Pro 64-bit
 
 

Well, unfortunately there isn't one.
My System SpecsSystem Spec
07 Oct 2015   #6
beret21

Windows 7 Ultimate x64
 
 

Quote   Quote: Originally Posted by RoasterMen View Post
Well, unfortunately there isn't one.
O There is to set a priority but none there to set affinity i should goto microsoft then !
My System SpecsSystem Spec
10 Oct 2015   #7
Alejandro85

Windows 7 Ultimate x64
 
 

NirCmd can do this. One of its multiple options precisely involves sets the CPU affinity of existing processes:
NirCmd Command Reference - setprocessaffinity
My System SpecsSystem Spec
10 Oct 2015   #8
Layback Bear

Windows 7 Pro. 64/SP-1
 
 

Okay folks I'm lost again.
With beret21 system specs, why would one want to do such a thing?
My System SpecsSystem Spec
11 Oct 2015   #9
Pyprohly

Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan
 
 

PowerShell can set a process' affinity. See SO answer.
My System SpecsSystem Spec
Reply

 Set AFFINITY of a game




Thread Tools Search this Thread
Search this Thread:

Advanced Search




Similar help and support threads
Thread Forum
Processor Affinity - Add Set Affinity to Context Menu
How to Add or Remove "Run with CPU Affinity" to the Context Menu By default, Vista, Windows 7, and Windows 8 runs an application on all available cores of the processor. If you have a multi-core processor, then this will show you how to add or remove Run with CPU Affinity from all...
Tutorials
All games crash unless I set affinity - 2 cores
Starcraft 2, Company of Heroes and now it looks like Dragon Age 2 as well. Basically, every game crashes unless I set affinity to 2 cores, the crashes actually look like graphics crashes but it is always fixed by setting affinity to 2 cores, the graphics will go weird often accompanied by...
Gaming
Save process priority and affinity
Hello, I'm running a few gameservers myself on Windows Server 2008 R2 but I'm wondering if it's possible to make my system recognize that the process was ran earlier, and it'll apply the correct affinity and priority. The problem is that I used to use ProcessLasso, but after 40 days of uptime...
Performance & Maintenance
How to set affinity for Media Center?
How do I assign Windows Media Center to one core? I don't know all the process names. If someone knows what they are I think I could do it with task manager.
Media Center
Processor Affinity - Set for Applications
How to Set Processor Affinity to an Application in Windows 7 Processor affinity or CPU Pinning enables the binding and un-binding of a process or thread to a physical CPU or a range of CPUs, so that the process or thread in question will run only on the CPU or range of CPUs in question,...
Tutorials
Set affinity in task mgr as default
I run a screen magnifier/reader that I want to use both my cpu's but at the moment it is set to only use one.I can change it manually to two but it reverts back to one after reboot. I do that in task manager. How can I change it to both cpu's as default?
Performance & Maintenance


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 13:21.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App