Jump to content
Sign in to follow this  
John_Cillis

AffinityMask Tweak

Recommended Posts

Guest
I just tried all the options and found out that the best is affinitymask=255 (or 254 if you want to have a free core for TrackIR or something else).
I guess that should be 127 and not 254...? 255 is 8 cores and 127 is 7 cores... right?

Share this post


Link to post
Share on other sites
I guess that should be 127 and not 254...? 255 is 8 cores and 127 is 7 cores... right?
It seems from John's investigation that you can select or deselect any of the 8 cores available on a Core i7 chip simply by setting or resetting the bits as desired. To be somewhat verbose, and to paraphrase John's notation, the alternative ways of deselecting 1 core from use while running FSX on an i7 chip are:Dec Value / Core #_____7 6 5 4 3 2 1 0254__1 1 1 1 1 1 1 0 253__1 1 1 1 1 1 0 1251__1 1 1 1 1 0 1 1247__1 1 1 1 0 1 1 1239__1 1 1 0 1 1 1 1223__1 1 0 1 1 1 1 1191__1 0 1 1 1 1 1 1127__0 1 1 1 1 1 1 1Both 127 and 254 are options in this case.

Mike Beckwith

Share this post


Link to post
Share on other sites
I guess that should be 127 and not 254...? 255 is 8 cores and 127 is 7 cores... right?
Like Mike said, if you set it to 254 all cores work inside FSX except the first one.

Alvega

CPU: AMD 7800X3D | COOLER: Cooler Master MasterLiquid 240L Core ARGB | GPU: RTX 4070 TI Super 16GB OC | Mobo: ASUS TUF GAMING X670E-PLUS WIFI |
RAM: 32 GB Corsair Vengeance RGB DDR5 6000MHz PC5-48000 2x16GB CL36 | SSDs: WD Black SN770 2TB NVMe SSD (WIN11), WD Black SN850X SSD 2 TB M.2 2280 PCIe Gen4 NVMe (MSFS), Crucial MX500 2TB (Other stuff) | CASE: Forgeon Arcanite ARGB Mesh Tower ATX White | Power Supply: Forgeon Bolt PSU 850W 80+ Gold Full Modular White 

Share this post


Link to post
Share on other sites

Hello,I'd like to give this tweak also a try...But: Is it useful for SP2? Or does it also have an affect to tweak with "affinity"?And: to set it on the last 3 cores for a quadcore, what number do I have to choose?Thank you very much!


Guenter Steiner
--------------------------------------------------------------------------------------

Betatester for: A2A, LORBY, FSR-Pillow Tester
--------------------------------------------------------------------------------------

Share this post


Link to post
Share on other sites

The Affinity Mask tweak has been possible since the release of SP1, so if you have SP2 installed then it will work for you.

And: to set it on the last 3 cores for a quadcore, what number do I have to choose?
Dec Value / Core #____3 2 1 007__0 1 1 17 would be the bit mask you would use according to John's notation. Alternatively you could experiment with setting and resetting the different bits to see which one works best for you. The bit mask values you could try in order to use only three cores while setting one aside for use by some other process would be: 14, 13, 11, 7.

Mike Beckwith

Share this post


Link to post
Share on other sites

Thank you very much, Mike.I'll try it out!


Guenter Steiner
--------------------------------------------------------------------------------------

Betatester for: A2A, LORBY, FSR-Pillow Tester
--------------------------------------------------------------------------------------

Share this post


Link to post
Share on other sites

Hello,Does someone know what I need to use with my HT system? 1 or 2 cores?Thanks in advance


Emile EBBR Z590 Aorus Elite, i9-11900K 3.5Ghz Nvidia RTX 3060, 16 GB Mem, SSD 1Tera + other HDDs, Dual Boot . Win11 Pro X64

Share this post


Link to post
Share on other sites
Guest Nick_N

Unless Intel has changed how hyperthread works and without it enabled only 1/2 of each physical core in i7 is being used, turning it on (IMHO) may be netting the psychological result of seeing activity in the boxes, or, the change really is affecting an issue which could be resolved through other means but in reality had nothing to do with HT being enabled/disabled to begin with.It is my understanding that FSX SP2 is multicore aware, not hyperthread... someone from Aces would need to ring in on that If you are at 4Ghz and on the fence with temps with i7 enabling the feature can throw you over the top on heat, so do be aware of that. what this reminds me of... VSYNC DISABLEDI can dig up thread after thread after thread where people SWEAR with Vsync disabled the sim ran higher frames and smootherOF course it runs higher frames... Vsync locks the frames at the refresh rate of the monitor. What I also found amazing is those running WINDOW MODE making the same statement about performance after disabling Vsync... when Vsync DOES NOT work in Windows Mode, at all!The psychological result of seeing the frame counter move over the refresh rate allowed all sorts of perfomance 'sightings' to occur all over the netI usually find when things like this get posted the results are one person says they see a difference and another says they cant see a difference, and then another says they see a small change.. then another says the system runs worse.In that, we have a tweak that does not exist but people will see what they want to see based on readouts, benchmark software and other visual aids that are giving the person what they want to see and its simply applied all the way through, or, the change really is affecting an issue which could be resolved through other means but had nothing to 'truly' do with HT being enabled/disabled to begin with. Now.. as I said, assuming Intel has not changed how hyperthread works with i7 and it somehow does not allowing full access to the physical cores when disabled, I do not see it helping. And if I had to choose between 4Ghz and HT enabled due to temps, I know which one I will take.I have run tests on properly tuned systems for both OS and FSX going back into October and I saw absolutely nothing was gained or lost by enable/disable HT in i7 on the testbed systems I ran.I normally find those who use the affinity mask tweak and say killing a core to FSX makes the system work better and run smoother in application, see that result because FSX is NOT correctly tuned, or, a 3rd party addon is influencing the result. What they are doing is a 6 of 1, 1/2 dozen of the other.. instead of using the slider to poke the software into using the hardware, or using Windows CPU Affinity for the 3rd party app they kill one part of the hardware to FSX which then tickles the rest into action. Some 3rd party addons should have their own resource and is better off not being placed on the same primary (0-1) cores as FSX.The same thing can be accomplished by assigning CPU Affinity in Windows to the 3rd party app.There are a lot of different ways to accomplish the same goalUsing the Affinity Mask in RTM was required however past SP1 that was pretty much done away with.. the app will find the core resources without the line edit if they are there and if the system and BIOS are working correctly.I will look at it again when I get time to see if I missed something.. which is possible :( but nothing I saw when I ran i7 tests back in Oct-Nov indicated HT was doing anything for FSX with i7 except heating up the proc in a high clock. All my test were run on SP2/Acceleration as I do not use RTM or SP1 at all..I am also on WindowsXP x64 although I did run FSX on Windows7 and saw no difference either so there are few different wildcards out there in configurations that may need to be looked at.The bottom line to all this is.. if you think you have found something that works for you. no matter the 'what' or 'how'.. use it :(

Share this post


Link to post
Share on other sites
On my I7 it also seems to be smoother if i leave 1 core free (by setting the mask to 254 instead of 255). I wonder why...
Since the OS will tend to use Core0 (the first core), it makes some sense that running FSX on the other cores would help.Just an uneducated guess :(

Bert

Share this post


Link to post
Share on other sites
Using the Affinity Mask in RTM was required however past SP1 that was pretty much done away with.. the app will find the core resources without the line edit if they are there and if the system and BIOS are working correctly.
Nick, I wonder if more cores really add to the performance, or possibly just add to the congestion.FSX is multi-core aware and will assign work, but does this always translate into better performance?Just like a freeway with additional lanes does not necessarily enable more traffic, if the lanes merge backinto just one lane further along..I can see all cores on my Q6600 getting used in the default configuration, but with the mask set to 6 (0110), only two cores get used by FSX and the sim runs smoother.Not really better fps, but more consistency and less "hesitation" when making turns and overall smoother feel.The fact that I get at least as good performance with two cores enabled as with four, tells me that the last two cores cannotbe doing much to help. The only benefit I can point to is a faster initial load. Maybe my system is congested somewhere else,but I've got FSX on a separate Raptor drive, running the CPU at 3.0GHz, defrag, and don't run any additional stuff. I know that some systems run better with more autogen rather than less, and I wonder if this is a similar case, where a differentload pattern is handled better.. although common wisdom might have expected a different outcome.

Bert

Share this post


Link to post
Share on other sites
I have run tests on properly tuned systems for both OS and FSX going back into October and I saw absolutely nothing was gained or lost by enable/disable HT in i7 on the testbed systems I ran.
Did you run those tests using the affinity mask tweak set to 254? Because that is what really makes the difference. If you enable HT on I7 but don't set the mask tweak, it is as good as nothing. Otherwise you would instantly notice faster (much faster) loading times (i clocked them), be it texture loading, aircraft selection menu, etc. By the way, i'm with SP2 also. As to the temps, my 720 is clocked to 3.5 and i have no problem with them. Never exceed high 50's running FSX.Cheers

Alvega

CPU: AMD 7800X3D | COOLER: Cooler Master MasterLiquid 240L Core ARGB | GPU: RTX 4070 TI Super 16GB OC | Mobo: ASUS TUF GAMING X670E-PLUS WIFI |
RAM: 32 GB Corsair Vengeance RGB DDR5 6000MHz PC5-48000 2x16GB CL36 | SSDs: WD Black SN770 2TB NVMe SSD (WIN11), WD Black SN850X SSD 2 TB M.2 2280 PCIe Gen4 NVMe (MSFS), Crucial MX500 2TB (Other stuff) | CASE: Forgeon Arcanite ARGB Mesh Tower ATX White | Power Supply: Forgeon Bolt PSU 850W 80+ Gold Full Modular White 

Share this post


Link to post
Share on other sites
Guest Nick_N
Did you run those tests using the affinity mask tweak set to 254? Because that is what really makes the difference. If you enable HT on I7 but don't set the mask tweak, it is as good as nothing. Otherwise you would instantly notice faster (much faster) loading times (i clocked them), be it texture loading, aircraft selection menu, etc. By the way, i'm with SP2 also. As to the temps, my 720 is clocked to 3.5 and i have no problem with them. Never exceed high 50's running FSX.Cheers
as I said, I do not use any mask tweak and I do not use SP1 either so I will revisit it when I get time and look at the resultWhat I would really like is someone from Aces to ring in and post if FSX is HT or simply multicore because if it does not take advantage of Intel HT I want the right frame of mind in place as I observe results. .. I was also under the impression affinity mask was no longer needed after SP2 and I would like that clarified if possible.3.5 is not a high clock.. most run 4 with that chip in which HT may push them over in stress tests.. FSX is not a stress test for a proc. Proper stress tests are performed to assure safe operation in any application in a clock by applying a simulated max condition.

Share this post


Link to post
Share on other sites
as I said, I do not use any mask tweak and I do not use SP1 either so I will revisit it when I get time and look at the result
I do not use SP1 either. These results are in SP2, as i said before.
I was also under the impression affinity mask was no longer needed after SP2 and I would like that clarified if possible.
I think it is already clarified. With SP2 without the affinity mask only 4 cores are active. With the affinity mask, all the 8 are active and we can see the improvements. Check it for yourself, just enable HT and set the mask.Maybe , as you said before, Intel changed something on the I7 HT.

Alvega

CPU: AMD 7800X3D | COOLER: Cooler Master MasterLiquid 240L Core ARGB | GPU: RTX 4070 TI Super 16GB OC | Mobo: ASUS TUF GAMING X670E-PLUS WIFI |
RAM: 32 GB Corsair Vengeance RGB DDR5 6000MHz PC5-48000 2x16GB CL36 | SSDs: WD Black SN770 2TB NVMe SSD (WIN11), WD Black SN850X SSD 2 TB M.2 2280 PCIe Gen4 NVMe (MSFS), Crucial MX500 2TB (Other stuff) | CASE: Forgeon Arcanite ARGB Mesh Tower ATX White | Power Supply: Forgeon Bolt PSU 850W 80+ Gold Full Modular White 

Share this post


Link to post
Share on other sites
Guest Nick_N
I do not use SP1 either. These results are in SP2, as i said before.I think it is already clarified. With SP2 without the affinity mask only 4 cores are active. With the affinity mask, all the 8 are active and we can see the improvements. Check it for yourself, just enable HT and set the mask.Maybe , as you said before, Intel changed something on the I7 HT.
There is nothing I can find which indicates FSX SP2 will not automatically find the resources available and spawn threads making use of multithread if it is available.JOBSCHEDULER]AffinityMask=nIs designed to set and control scheduling of threads on cores. However the setting is based on: n = number of cores scheduled, not THREADS so I must assume that means if more than one THREAD is enabled per CORE assigned they will be available to FSX without this edit to the config in a properly functioning BIOS and system================================The processor bitmask shows you what cores will be enabled ( 1 ) and what cores will be disabled ( 0 ), primarily to allow you to see the pattern and be able to pick a bitmask for 8 and 16 cores or more when they are available.================================Therefore information from Phil or another team member such as Adam who did the great terrain engine work would greatly help with this in clarification.Multithread is not Hyperthreadhttp://www.intel.com/cd/ids/developer/asmo-na/eng/20456.htmIn no article or blog entry can I find any reference to the use of Simultaneous MultiThreading (SMT) or 'hyperthread' which is different from 'Mutltithread'http://www.fsinsider.com/tips/Pages/SP1How...uInstallIt.aspxhttp://www.fsinsider.com/team/Pages/Multip...sNoWaiting.aspxhttp://www.gamasutra.com/view/feature/3689...oft_.php?page=1 Microsoft Flight Simulator X, successfully takes advantage of multithreading and Intel

Share this post


Link to post
Share on other sites
Guest SkullxBones
Since the OS will tend to use Core0 (the first core), it makes some sense that running FSX on the other cores would help.Just an uneducated guess :(
Makes since to me. I just tried AffinityMask=6 on my Q6600. Did not notice any FPS increase but it did seem smoother. I tried both extremes, PMDG747 in KLAX with lots of traffic and then the default 172 in the middle of nowhere and in both cases there was almost no stutters which was unusual becasue with my FPS set to unlimited, I would normally get stutters when I pan around outside in spot view in both those situations. Maybe it is the placebo effect, or FSX in one of it's good moods, but I like it so far. Would like to hear the results from more concrete testing on this. If it's true, this is a major tweak.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...