PDA

View Full Version : FSX CFG question



jeansy
September 7th, 2012, 22:34
im a little confused, can some shed some light on this

I did Bojote's FSX.cfg tweaker today and it came up with this one


[JOBSCHEDULER]
AffinityMask=21504

I was under belief that 14 was the optimum value for quad cores

can some shed some light on this value please as its a huge difference to what a lot guides suggest

stansdds
September 8th, 2012, 03:44
The old affinity mask setting of 14 was generally good for Core2Quad CPU's. Based on the affinity mask that was suggested for you, I'd say you have a newer generation of multi-core CPU, maybe an I7 cpu?

mal998
September 8th, 2012, 11:24
Here's what NickN had to say about affinity masks. Hope it sheds some light.

AFFINITY MASK:

This is ONLY for quad core processors. I have never seen a dual core make use of this tweak

i7.. Do not bother setting more than a 4 core affinity mask

Please reserve using this tweak until you have completed all other tuning. Once you have your sim running the best you can, then you may try this. It tends to not work well with Intel i7 and DO NOTE, Hyperthread is USELESS to FSX and therefore trying to set a high affinity mask for 8 cores is USELESS. 4 of the 8 i7 cores are virtual and FSX will not use them, at all, regardless of what you see on the CPU monitor.

In the FSX.cfg add the following if it is not already there

[JOBSCHEDULER]
AffinityMask=n

use these settings for N as you test and you must EXIT the sim and relaunch between changes

n=14

n=7


Here is how it works.. the setting converts 1s and 0s representing you processor cores. 4 cores active are 'binary' 1111, two cores 11

With a setting of 14 that means we convert 14 to binary or 1110

The LAST value is the FIRST core.. its backwards!

Therefore a setting of 7 or binary 0111 means the LAST core is disabled to FSX and with 14 1110 the FIRST core is disabled to FSX

I have never needed this tweak in any system I have tuned however with all the different hardware out there the tweak does have merit and it is a 'try and see' tweak for smoothness. However please DO reserve this test for last after all other tuning is complete.

jeansy
September 8th, 2012, 17:09
Here's what NickN had to say about affinity masks. Hope it sheds some light.

AFFINITY MASK:

This is ONLY for quad core processors. I have never seen a dual core make use of this tweak

i7.. Do not bother setting more than a 4 core affinity mask

Please reserve using this tweak until you have completed all other tuning. Once you have your sim running the best you can, then you may try this. It tends to not work well with Intel i7 and DO NOTE, Hyperthread is USELESS to FSX and therefore trying to set a high affinity mask for 8 cores is USELESS. 4 of the 8 i7 cores are virtual and FSX will not use them, at all, regardless of what you see on the CPU monitor.

In the FSX.cfg add the following if it is not already there

[JOBSCHEDULER]
AffinityMask=n

use these settings for N as you test and you must EXIT the sim and relaunch between changes

n=14

n=7


Here is how it works.. the setting converts 1s and 0s representing you processor cores. 4 cores active are 'binary' 1111, two cores 11

With a setting of 14 that means we convert 14 to binary or 1110

The LAST value is the FIRST core.. its backwards!

Therefore a setting of 7 or binary 0111 means the LAST core is disabled to FSX and with 14 1110 the FIRST core is disabled to FSX

I have never needed this tweak in any system I have tuned however with all the different hardware out there the tweak does have merit and it is a 'try and see' tweak for smoothness. However please DO reserve this test for last after all other tuning is complete.


Cheers,

Its interesting ive been playing with it for the past 24hrs and the value suggested to me works very well, FYI is an I7 with hyper threading turned on

Funny enough it was the only suggestion given, and it appears to have paid off

Its amazing how much info out there that contradicts or is behind

So far im happy with and going to keep using for now, and see how it pans out

IanHenry
September 8th, 2012, 23:29
Hi,
I found this a useful little article :

http://forum.avsim.net/topic/370594-read-before-posting-software-hardware-guide-for-fsx/

Hope it's of some help.

Regards,
Ian.

PHo17
September 9th, 2012, 00:23
I made a little table of the matter (which doesn't require maths)

[JOBSCHEDULER]
AffinityMask=n

n core1 core2 core3 core4
15 on on on on
14 off on on on
13 on off on on
12 off off on on
11 on off off on
10 off on off on
9 on off off on
8 off off off on
7 on on on off
6 off on on off
5 on off on off
4 off off on off
3 on on off off
2 off on off off
1 on off off off
(0 off off off off //useless according to this logic ;-)

(Actually the first core is core0, but I think this is more clear)

Pekka

********************************** some math beoynd the numbers if anyone is interested ***********************************************

Because technically it's easiest to realize numbers as only 2 states computers originally use 2 digit (0 and 1) or binary numbers. So for example number 14 in decimal number system (which is familiar to us) must be expressed as binary number and vice versa. This is made by using powers of 2. So for example:

14 = 8 + 4 + 2 + 0 = 2^3 + 2^2 + 2^1 + 0 or 1 (2's power 3), 1 (2's power 2), 1 (2's power 1) and 0 (2's power 0 ; 2^0=1) which is 1 1 1 0

stansdds
September 9th, 2012, 04:52
If I recall correctly, hyperthreading doubles the number of CPU cores the system recognizes, basically splitting each core into two cores. If you turn off hyperthreading, then run Bojote's tweaker you will get a two digit affinity mask number. Hyperthreading fell out of favor with the introduction of the Core2Quad. I have no experience with the I7 CPU's so I don't know if hyperthreading helps or hurts their performance.

fxsttcb
September 9th, 2012, 10:08
With HyperThreading enabled, each physical core has two seperate execution units(Virtual Cores...Secondary Cores...Threads...Pick one!).
HT enabled shares the common physical core's resources between them.
This is why, in many cases, HT can actually reduce performance, and for FS purposes, possibly limit an overclock to a lesser speed.

As for Affinity, during my searches, I have seen some conflicting info on actually which cores the binary equivalent digits control individually.
Most Windows and FSX Affinity posts say that the binary's least significant digit(far right) is assigned to Core 0.
Which I tested and found to be correct for FSX. I tested to see the effect using only a single core enabled via an affinity mask.
Doing that, I identified the enabled core, via the Resource monitor with FSX cranked up.

On my Dual Core:
AffinityMask=1(binary 01) enabled Core 0,
AffinityMask=2(binary 10) enabled Core 1,
and AffinityMask=2 or no assignment(default) enabled both cores.
Which AffinityMask's Binary equivalent actually turns each core on/off is an important distinction.

Quad Core NO HT:


Mask, Core 3, Core 2, Core 1, Core 0, Binary
15 On On On On 1111
14 On On On Off 1110
13 On On Off On 1101
12 On On Off Off 1100
11 On Off On On 1011
10 On Off On Off 1010
9 On Off Off On 1001
8 On Off Off Off 1000
7 Off On On On 0111
6 Off On On Off 0110
5 Off On Off On 0101
4 Off On Off Off 0100
3 Off Off On On 0011
2 Off Off On Off 0010
1 Off Off Off On 0001

I'm quite interested in this because, when I get my new rig(undecided, Z77 or X79), I am, hopefully, going to push it to it's absolute limits.
I intend to use the FSX.cfg AffinityMask= assignment, to let FSX use the coolest running 3(Quad), or 5(Hexa), cores, with HT off...Don

FlameOut
September 9th, 2012, 15:27
Well, to stir up the pot even more and keep my brain :isadizzy: a link to FSX Times : http://fsxtimes.wordpress.com/2010/08/18/affinitymask/

I have an I-7 3960X 6-core and my "... Bojote's FSX.cfg tweaker ..." assigned my FSX cfg. this value...

[JOBSCHEDULER]
AffinityMask=3584

.... still don't understand all this voodoo magic, but FSX is waaaaaaay better now, than with my old P4 HT...

jeansy
September 9th, 2012, 22:07
Interesting

When u get home I might turn off hyper threading and see what changes I need and what performance differences are observed

fxsttcb
September 10th, 2012, 02:38
I have an I-7 3960X 6-core and my "... Bojote's FSX.cfg tweaker ..." assigned my FSX cfg. this value...

[JOBSCHEDULER]
AffinityMask=3584

.... still don't understand all this voodoo magic, but FSX is waaaaaaay better now, than with my old P4 HT...
From what you, and jeansy, got for AffinityMask= results, it looks to me like Jesus' tweaker is struggling with Hexacore, HT "On", Calcs, or it is being very, very, conservative with it's assignments
With FSX running, you can verify the affinity setting using Task Manager/Processes Tab, Right Click fsx.exe->Set Affinity.
How many Cores are shown? How many are activated?
Your binary equivalent of 3584(111000000000) should only be showing the last 3 of the available 12 execution units(Cores).

To give Windows both execution units of Physical Core0(Core0, Core1), and FSX all of the remaining 10, the binary would be 111111111100.
That would be AffinityMask=4092, also noted as such in your linked page...Don

Sieggie
September 10th, 2012, 05:15
If I remember correctly when I did my research on affinity mask, if you had HT turned on you wanted to set the low order bit of the core on and the other off. Bejotes config gave me a 1344 for my 6 core I7 which is 010101000000. This should force the core to not hyperthread when FSX is using it and give better performance.

Dave

fxsttcb
September 10th, 2012, 06:44
If I remember correctly when I did my research on affinity mask, if you had HT turned on you wanted to set the low order bit of the core on and the other off. Bejotes config gave me a 1344 for my 6 core I7 which is 010101000000. This should force the core to not hyperthread when FSX is using it and give better performance.

DaveHyperThreading is not controlled via an affinitymask entry. It is only enabled/disabled in BIOS.
Your 6 Core chip has exactly that, 6 Physical Cores. It also has two Physical Execution Units per Core and a single set of resources to be shared between the EUs. HyperThreading "On" enables both EUs, effectively giving you 12 "Virtual Cores"(Core0-Core11).
Those Virtual Cores/EUs must share the single set of common physical resources when HyperThreading is enabled.

Any Core/Virtual Core/Thread that is not assigned, via the affinitymask= entry to FSX, will be available to any other running entity.
That does not say they will be used. Just available. If they do get used, because they share resources, they can impact FSX performance.

For example; Say Virtual Core0(Phys Core0) is assigned to FSX and it's counterpart Virtual Core1(also Phys Core0) is not assigned, when Virtual Core1 is actively being used by something else, the shared resource(s) in use will not be available to FSX at that time.
If the shared resource is being flip-flopped between FSX and the other app at 5GHz, then the FSX share is equivalent to half of that. 2.5GHz
A little oversimplified but you get the jist.

Unless you are running other CPU intensive apps, concurrent with FSX, 1 Physical Core(2 Virtual, HT "On") for Windows and other running processes, should give FSX it's maximum potential. FSX, being primarily a single threaded app, will not push the use of the available cores/threads to 100%, so, with a HexaCore CPU you can get away with much less of your available resources assigned to it.

With 1344 / 010101000000 the first Virtual Core/Thread of Physical Cores 3, 4, and 5(Virtual Cores 6, 8, and 10) are assigned to FSX.
Effectively, that leaves the shared resources of those(Virtual Cores 7, 9, and 11) available to anything that needs them.

Personally, I don't want my FSX to share resources with anything, so, limiting FSX to 3 Physical cores; 111111000000 binary, 4032 decimal, or, 000000111111 binary, 63 decimal, or any combination that uses both EUs on 3 or more Physical Cores is what I would prefer on a Hex.
That scenario would give FSX half of the CPU, and everything else can share the remaining half...Don

FlameOut
September 10th, 2012, 17:29
Well, I went back over to Bojote's and I confirmed that I was "doing the analysis and download of the tweaked FSX.cfg file, same thing :

[JOBSCHEDULER]
AffinityMask=3584


With FSX running, you can verify the affinity setting using Task Manager/Processes Tab, Right Click fsx.exe->Set Affinity.
How many Cores are shown? How many are activated?..... this is what I have, if I did it correctly :

72455

Cpu 0 through Cpu 11 , all "checked"

I guess I do have HT "on"

Still very confusing :isadizzy:

PHo17
September 10th, 2012, 22:23
Take any process - the default setting seems to be "on" for all cores/virtual cores (depending HT setting). Some processes are unaccessible (not able to change affinity). How does this make sense to what has been said here? Should other processes be ticked off from the cores FSX is using? :isadizzy:

Does setting the prioroty make any help for FSX? There also the default value seems to be "normal" for every process.

Pekka

fxsttcb
September 11th, 2012, 09:03
Take any process - the default setting seems to be "on" for all cores/virtual cores (depending HT setting). Some processes are unaccessible (not able to change affinity). How does this make sense to what has been said here? Should other processes be ticked off from the cores FSX is using? :isadizzy:

Does setting the prioroty make any help for FSX? There also the default value seems to be "normal" for every process.

PekkaThe fsx.cfg affinitymask= settings are obviously not adhering to the binary equivalent as stated in the windows forums.

"Cpu 0 through Cpu 11, all 'checked'" with fsx.cfg's AffinityMask=3584(Binary 111000000000, from calculator) doesn't follow the logic.
That Binary should only give CPU 9, 10, and 11 for fsx.exe. Is there something that I've missed in my research?
All CPUs(0-11) dedicated to FSX should give awesome performance, but, begs the question; how does a Dec 3584/Binary 111000000000 enable all 12 execution units(CPU0-CPU11)?

[edit] My understanding was(*) that each available CPU, HT on or off, was dedicated to FSX by it's location in the binary string, with CPU0 being the farthest right of the binary digits.

Further checking/research of "Task Manager/Processes Tab, Right Click fsx.exe->Set Affinity" tells me that what is shown are the CPU EUs that are allowed to run FSX, not just the ones that the affinitymask= is supposedly dedicating to it.
What is flawed, in that, is that the CPUs I enable with affinitymask=, are all still listed on other Running Apps as allowed to run that CPU.
I do know that system files will always have access to any thread, but, I tried with games, notepad, IE, etc, and they all are allowed.
I suppose that disallowing CPUs for all other apps could work, but...PITA!

Obviously that method isn't reliable when trying to determine which CPUs are enabled/dedicated to FSX. Sorry, for the bum steer. :redf:
The one consistent indicator of affinitymask=, at least on my system, is the "Resource Monitor".
With FSX pushed hard, there is no doubt which cores are assigned via affinitymask=.

* [edit2] With FSX paused, and a bunch of other apps running, I see more usage on the CPU that is assigned to FSX, than with FSX paused and no other apps running. That leads me to believe that affinitymask= may only give FSX "maximum priority" to, rather than dedicating, those CPUs it enables. That ultimately makes more sense to me...

I've seen no difference when giving higher "Priority" to FSX, but, my rig is challenged enough that it's possible gains may not be visible...Don