• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

Feature Suggestion: Assigning Interrupt affinities

Joined
Jun 8, 2021
Messages
45 (0.04/day)
Another thing many users do to help with latency issues is to assign the gpu driver (and optionally its pcie bridge) to a specific core, like described by Calypto here:


Very briefly, it helps alleviating the stress on core 0.
This is achieved by Microsoft’s Interrupt-Affinity Policy Tool which is tedious.

An integration would be a big time saver.
Note that users with HT/SMT enabled would have to proceed differently.
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
27,032 (3.71/day)
Processor Ryzen 7 5700X
Memory 48 GB
Video Card(s) RTX 4080
Storage 2x HDD RAID 1, 3x M.2 NVMe
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 10 64-bit
This has been added to test attached build, please confirm
 

Attachments

  • NVCleanstall.exe
    3.4 MB · Views: 146
Joined
Jun 8, 2021
Messages
45 (0.04/day)
Looks great! I chose specific core 4 in my test and had this result:
So it did successfully assign the bridge's affinity but not the gpu itself. I'm not quite sure if that makes a difference in the end.

According to Calypto, the actual gpu affinity must be changed.

There are also users reporting freezing when msi mode is set before affinities. (both using a 1080TI - no such reports on other cards)
Is there a way to first apply affinities, have the driver or system restart and then apply msi mode afterwards?
 
Last edited:

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
27,032 (3.71/day)
Processor Ryzen 7 5700X
Memory 48 GB
Video Card(s) RTX 4080
Storage 2x HDD RAID 1, 3x M.2 NVMe
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 10 64-bit
So it did successfully assign the bridge's affinity but not the gpu itself. I'm not quite sure if that makes a difference in the end.
Very strange, it should have set the GPU's affinity. I'll test with the Microsoft Tool

Is there a way to first apply affinities, have the driver or system restart and then apply msi mode afterwards?
From what I understand affinities and priorities have no effect until MSI is enabled. This could be placebo? What's your sample size?
 
Joined
Jun 8, 2021
Messages
45 (0.04/day)
It's only 2 users, both with a 1080TI, who reported this issue when setting msi mode before affinities.
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
27,032 (3.71/day)
Processor Ryzen 7 5700X
Memory 48 GB
Video Card(s) RTX 4080
Storage 2x HDD RAID 1, 3x M.2 NVMe
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 10 64-bit
Does this build work better? Fixed some bugs in the MSI affinity code
 

Attachments

  • NVCleanstall.exe
    3.4 MB · Views: 222
Joined
Jun 8, 2021
Messages
45 (0.04/day)
Yes, this time I picked core 7 and the gpu is assigned properly!
It's great already but I would suggest an optimal scenario:
The pci-bridge was still assigned to core 4 from the previous test. It'd be nice if previous affinities (only of gpu and its pci-bridge) were removed and then both the gpu and it's pci-bridge were assigned to the same specified core(s).
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
27,032 (3.71/day)
Processor Ryzen 7 5700X
Memory 48 GB
Video Card(s) RTX 4080
Storage 2x HDD RAID 1, 3x M.2 NVMe
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 10 64-bit
I didn’t touch the bridge, it looks for devices of gpu class, with vendor 10de, with driver by nvidia
 
Joined
Jun 8, 2021
Messages
45 (0.04/day)
Yes, but the corresponding bridge should be assigned to the same core as the gpu.
1623883507804.png

Also, shouldn't this only reach from #0 - #9 for my 10 cores processor?
1623883674663.png
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
27,032 (3.71/day)
Processor Ryzen 7 5700X
Memory 48 GB
Video Card(s) RTX 4080
Storage 2x HDD RAID 1, 3x M.2 NVMe
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 10 64-bit
Yes, but the corresponding bridge should be assigned to the same core as the gpu.
No reason imo. The PCIe path has nothing to do with interrupt handling

Also, shouldn't this only reach from #0 - #9 for my 10 cores processor?
Correct, typical off-by-one error. Will fix. Also start at "1" to make it more readable for humans? Task Manager starts at 0 though
 

sewerin0911

New Member
Joined
Jun 12, 2021
Messages
7 (0.01/day)
These are the right settings for a 5900X with SMT right?

Thanks for adding HDCP btw.
1623979594686.png
 
Joined
Jun 8, 2021
Messages
45 (0.04/day)
I'm personally not proficient enought to tell with certainty. In my experience you would assign SMT affinities either to every other core (so only the physical cores are ticked) or to the specific core + it's thread. I'm not sure if Spread Across All Processors helps over default. Try Calyptos suggestion for SMT in the guide and maybe someone more versatile can shed some light on it here.

No reason imo. The PCIe path has nothing to do with interrupt handling


Correct, typical off-by-one error. Will fix. Also start at "1" to make it more readable for humans? Task Manager starts at 0 though
Not sure - starting at "1" should be easier for inexperienced users, while it probably confuses everyone who is used to microsofts tool.
 

sewerin0911

New Member
Joined
Jun 12, 2021
Messages
7 (0.01/day)
I did it like that but also noticed a small bug here. Core starts at 0 (I have 24 Threads) and ends at 24. Actually it should be 23 :D

Also I set my cores like that without the logical cores.

1625323113167.png
 

Attachments

  • 1625322982760.png
    1625322982760.png
    16.3 KB · Views: 80

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
27,032 (3.71/day)
Processor Ryzen 7 5700X
Memory 48 GB
Video Card(s) RTX 4080
Storage 2x HDD RAID 1, 3x M.2 NVMe
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 10 64-bit

sewerin0911

New Member
Joined
Jun 12, 2021
Messages
7 (0.01/day)
Whoops lol, classic off-by-one error


any idea if the logical cores are 12..23 or 1,3,5,7,9.. ?
The even numbers are the real cores and the odd numbers are the logical cores. 0 -> real 1 -> corresponding logical core and so on...

I'm personally not proficient enought to tell with certainty. In my experience you would assign SMT affinities either to every other core (so only the physical cores are ticked) or to the specific core + it's thread. I'm not sure if Spread Across All Processors helps over default. Try Calyptos suggestion for SMT in the guide and maybe someone more versatile can shed some light on it here.


Not sure - starting at "1" should be easier for inexperienced users, while it probably confuses everyone who is used to microsofts tool.
It is recommended to not play around with affinities anymore. SpreadAcrossAllProcessors can help in fact with scalability for sure. However, it is recommended to set it to a specific core (with corresponding logical core if SMT is enabled). The specific core is usually one of the best cores, procedure especially known on Ryzen CPUs. I would leave it on Default since it does not affect much. I tested it...
 
Joined
Jun 8, 2021
Messages
45 (0.04/day)
Results.png

Results can differ quite much according to my testing. Unfortunately, it seems like Windows reassigns affinities randomly across boots (please correct me here if wrong) so that specifying one for the gpu has inconsistent results.

One core might be the best for one boot and the worst for another. Still, I think it can be beneficial to at least assign it away from core0 (the same is true for the USB controller for example which can result in more consistent mouse graphs...) due to most processes being active on that one by default - again please correct me here.

So overall it can't really hurt to at least have the gpu assigned to one specific core that is not core0, I guess?!
 
Top