Sign in to follow this  
Rockliffe

Advice on hyperthreading

Recommended Posts

Hey guys, can anyone offer some advice on whether I should have hyperthreading switched on or off with my new i7-6700k build. I run FSX-SE and have always understood that hyperthreading is redundant with FSX as it only runs on a single core. However, is that still the same train of thought or is there a good reason for running hyperthreading. I have previously run with a i5-2500k when I had AffinityMask =14. What should I do in this area, bearing in mind I'm running FSX-SE with a i7-6700. Thanks.

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

 I run FSX-SE and have always understood that hyperthreading is redundant with FSX as it only runs on a single core.

 

 

 

Not true, FSX runs on all cores. That's since Aces gave us the service packs years ago. The bulk of the work is on one core though. 

 

6700K all cores utilised but the other four virtual cores of little benefit. So depends what you do with your rig. For me, rarely sim these days so keep HT on. I don't think there are any application I run that benefit from HT, but my rig runs great anyway, overclocked with low temps, so I leave it on. 

 

There are some that claim scenery loads faster with HT on, but not definitive. If overclocking, HT off will drop the CPU temp by 10 degrees or so and enable a higher overclock. The higher overclock is probabaly more advantageous than an unconfirmed minor benefit from HT on.

 

That's my take on it anyway.

Share this post


Link to post
Share on other sites

Not true, FSX runs on all cores. That's since Aces gave us the service packs years ago. The bulk of the work is on one core though. 

 

6700K all cores utilised but the other four virtual cores of little benefit. So depends what you do with your rig. For me, rarely sim these days so keep HT on. I don't think there are any application I run that benefit from HT, but my rig runs great anyway, overclocked with low temps, so I leave it on. 

 

There are some that claim scenery loads faster with HT on, but not definitive. If overclocking, HT off will drop the CPU temp by 10 degrees or so and enable a higher overclock. The higher overclock is probabaly more advantageous than an unconfirmed minor benefit from HT on.

 

That's my take on it anyway.

 

Interesting. That's helpful information Martin, appreciated. So if I set hyperthreading on, what value should I set with AffinityMask?

Share this post


Link to post
Share on other sites

Howard,

 

Whether or not you run with Hyperthreading on or off depends on what other programs are running while you're flying.  If pretty much nothing else, then I'd say off.  In fact, off is usually the preferred, best performing setting.

 

The AF settings... there is an excellent description of AF in the AVSIM Setup Guide (located on the Top Right of all AVSIM pages which explains AF, so users can determine the correct value and set it themselves.  I think this is important to understand AF and what it does if one is going to stay in our hobby.

 

My very best wishes to you!

Share this post


Link to post
Share on other sites

For 6700K,  AM=85 works well (I'm currently using) and others like AM=116 (I used to use).

 

Jeff

Share this post


Link to post
Share on other sites

Howard,

 

Whether or not you run with Hyperthreading on or off depends on what other programs are running while you're flying.  If pretty much nothing else, then I'd say off.  In fact, off is usually the preferred, best performing setting.

 

The AF settings... there is an excellent description of AF in the AVSIM Setup Guide (located on the Top Right of all AVSIM pages which explains AF, so users can determine the correct value and set it themselves.  I think this is important to understand AF and what it does if one is going to stay in our hobby.

 

My very best wishes to you!

Thanks for the information Dave

 

For 6700K,  AM=85 works well (I'm currently using) and others like AM=116 (I used to use).

 

Jeff

Cheers Jeff.

. Appreciated. I'll check out the guide in detail.

Share this post


Link to post
Share on other sites

Networking and disk I/O are deeply multi-threaded and the Windows system as a whole benefits from HT enabled. If this was not the case we would know about it by now. Turning off HT on my 3960x delivers a noticeably stodgy performance compared to an obviously more zesty HT on. The problems come from the way certain apps utilise CPUs and most problems come from processes that don't consider two Logical Processors sharing the same core. FSX and FSX:SE consider the Hyperthreading mode but Prepar3D does not, so with P3D we need an AM for HT enabled or it will make double the processes per core in HT mode. On the four core with HT enabled you will see that FSX:SE uses AM=85. The real task is making sure apps running on the PC alongside FSX occupy the last two cores (last 4 LPs) and keep off the first two cores (first 4 LPs). If you're running addons that use SimConnect that means Networking, and so that aspect alone is improved with HT enabled. It is true that FSX and P3D utilise a monolithic thread design whereby they do not care about HT, but running on a properly set up HT system they run better by at least 5% or more. On a professional test harness these sims perform better with 5% more background throughput and HT enabled than they do with 5% overclock and HT disabled.

Share this post


Link to post
Share on other sites

Networking and disk I/O are deeply multi-threaded and the Windows system as a whole benefits from HT enabled. If this was not the case we would know about it by now. Turning off HT on my 3960x delivers a noticeably stodgy performance compared to an obviously more zesty HT on. The problems come from the way certain apps utilise CPUs and most problems come from processes that don't consider two Logical Processors sharing the same core. FSX and FSX:SE consider the Hyperthreading mode but Prepar3D does not, so with P3D we need an AM for HT enabled or it will make double the processes per core in HT mode. On the four core with HT enabled you will see that FSX:SE uses AM=85. The real task is making sure apps running on the PC alongside FSX occupy the last two cores (last 4 LPs) and keep off the first two cores (first 4 LPs). If you're running addons that use SimConnect that means Networking, and so that aspect alone is improved with HT enabled. It is true that FSX and P3D utilise a monolithic thread design whereby they do not care about HT, but running on a properly set up HT system they run better by at least 5% or more. On a professional test harness these sims perform better with 5% more background throughput and HT enabled than they do with 5% overclock and HT disabled.

That's really helpful information Steve, thanks. So should FSX-SE work on core 1, or does the PC decide where it will run while using other cores when needed? Sorry, I'm a little ignorant in this area of FSX!

Share this post


Link to post
Share on other sites

FSX makes good use of multi core and HyperTreading but when you get past 3 cores it is only improving ground texture loading. I've just been playing around a bit with my 6700K recently and without HT activated (with appropriate AM) I find it horrible for photo scenery. You can't fly very fast with a high LOD without getting blurries. With HT on (and appropriate AM) it is a lot better but still not as good for ground texture loading as my 6 core SandyBridge-E with HT on. That is despite the Skylake having a higher overclock than the SandyBridge-E.

 

But when it comes to FPS the Skylake is very noticible better with its beter architecture, DDR4 and higher overclock. (Give me Skylake-E soon please Intel...)

 

AM=85 is the FSX default for a quad core HTon. That's what you get if you don't put anything in the .cfg.

 

For a quad core I find AM=241 is the best all-round AM with HTon  whilst AM=249 works even better with some photoscenery but has the potential to not work so well depending on if you get any other CPU intensive activity running. (UK photoscenery with treescapes for example generates high CPU load on the FSX thread that loads pretty much everything that is read from your harddrives). I would also imagine any Wx software that generates a lot of cpu load at times injecting Wx might not work that great with AM=249.

 

If you activate HT and use AM=84 it is the equivalent of HToff AM=14.

Share this post


Link to post
Share on other sites

FSX makes good use of multi core and HyperTreading but when you get past 3 cores it is only improving ground texture loading. I've just been playing around a bit with my 6700K recently and without HT activated (with appropriate AM) I find it horrible for photo scenery. You can't fly very fast with a high LOD without getting blurries. With HT on (and appropriate AM) it is a lot better but still not as good for ground texture loading as my 6 core SandyBridge-E with HT on. That is despite the Skylake having a higher overclock than the SandyBridge-E.

 

But when it comes to FPS the Skylake is very noticible better with its beter architecture, DDR4 and higher overclock. (Give me Skylake-E soon please Intel...)

 

AM=85 is the FSX default for a quad core HTon. That's what you get if you don't put anything in the .cfg.

 

For a quad core I find AM=241 is the best all-round AM with HTon  whilst AM=249 works even better with some photoscenery but has the potential to not work so well depending on if you get any other CPU intensive activity running. (UK photoscenery with treescapes for example generates high CPU load on the FSX thread that loads pretty much everything that is read from your harddrives). I would also imagine any Wx software that generates a lot of cpu load at times injecting Wx might not work that great with AM=249.

 

If you activate HT and use AM=84 it is the equivalent of HToff AM=14.

Thanks matey, helpful advice. Appreciated.

Share this post


Link to post
Share on other sites

That's really helpful information Steve, thanks. So should FSX-SE work on core 1, or does the PC decide where it will run while using other cores when needed? Sorry, I'm a little ignorant in this area of FSX!

Remember that FSX:SE does not take notice of the AffinityMask setting in the .cfg, only FSX and P3D read this in and adjust accordingly. FSX:SE will do it's own thing unless manipulated by another program.

Share this post


Link to post
Share on other sites

Remember that FSX:SE does not take notice of the AffinityMask setting in the .cfg, only FSX and P3D read this in and adjust accordingly. FSX:SE will do it's own thing unless manipulated by another program.

Ah, so are you saying it's pointless to ad any such line to the cfg? I know that's what I thought you said....

Share this post


Link to post
Share on other sites

 

...The sim looks at the CPU and lays out it's main worker processes. It hopes that you have four logical processors, if not it places these together on less logical processors (LPs). That's why we specify AM=85 or AM=116 because these provide four unmasked logical processors. In binary 85=01010101 but since we are talking about a CPU with HyperThreading we place a comma between each pair (desktop CPUs we use have two per core) like this: 01,01,01,01 (some CPUs have more than two LPs per core - four per core on a two core AM=113=0111,0001). The first one the right (the first LP unmasked by a one is on core zero in this case) is where the first worker process is started and does the main work of rendering. We can get motherboards that can overclock just one core if we want and we would overclock this one. The other three (or more) worker processes (on those cores with an LP unmasked) do the background work. The second worker process manages the other processes and communicates with the first on a timely basis - so we keep other processes off of the cores of the first two unmasked LPs.

Share this post


Link to post
Share on other sites

Suggest you run Task Manager \ Performance tab along side FSX to see which processors are getting used.

 

That gives you a real time view.

 

If you change AM, you should see the corresponding change in the Task Manager graphs.

Share this post


Link to post
Share on other sites

Remember that FSX:SE does not take notice of the AffinityMask setting in the .cfg, only FSX and P3D read this in and adjust accordingly. FSX:SE will do it's own thing unless manipulated by another program.

 

This is news to me. Where did you get this information?

Share this post


Link to post
Share on other sites

I have to admit, I'm as confused now as I was at the beginning! I was hoping after explaining what processor I wsa using and which FSX version, I could have received some definitive direction. Don't get me wrong, I appreciate all the advice you guys offer and it is very much appreciated. But, SteveW, yourwell delivered reply is gobbledeegook to me!

Share this post


Link to post
Share on other sites

 

 


The sim looks at the CPU and lays out it's main worker processes. It hopes that you have four logical processors, if not it places these together on less logical processors (LPs).

 

It shouldn't do this - it should leave it all up to the Operating System and let the kernel scheduler decide what cores to run a particular thread on. AffinityMask merely tells it to call an OS function that tells the scheduler to only use particular cores for the threads.

 

Cheers!
 

Luke

Share this post


Link to post
Share on other sites

The sim looks at the CPU and lays out it's main worker processes. It hopes that you have four logical processors, if not it places these together on less logical processors (LPs).

 

 

It shouldn't do this - it should leave it all up to the Operating System and let the kernel scheduler decide what cores to run a particular thread on. AffinityMask merely tells it to call an OS function that tells the scheduler to only use particular cores for the threads.

 

Cheers!

 

Luke

 

That's exactly what it does Luke. Cheers!

 

 

This is news to me. Where did you get this information?

Study.

 

 

 

 

It's a shame to derail the discussion but I'll try to straighten this out for you Luke:

 

 

It shouldn't do this - it should leave it all up to the Operating System and let the kernel scheduler decide what cores to run a particular thread on. AffinityMask merely tells it to call an OS function that tells the scheduler to only use particular cores for the threads.

 

Cheers!

 

Luke

The sim decides where the main workers go according to the unmasked LPs - these contain many threads - more than 50. The Jobscheduler starts threads within that AM.

 

 

 

 

This is news to me. Where did you get this information?

Further to that study I just had time to retest FSX:SE and it seems that the current version 62615 does now take advantage of the AM in the .cfg so it can be set with an AM the same as FSX. Apologies for that, it seems to have been fixed.

Share this post


Link to post
Share on other sites

Hey guys, can anyone offer some advice on whether I should have hyperthreading switched on or off with my new i7-6700k build. I run FSX-SE and have always understood that hyperthreading is redundant with FSX as it only runs on a single core. However, is that still the same train of thought or is there a good reason for running hyperthreading. I have previously run with a i5-2500k when I had AffinityMask =14. What should I do in this area, bearing in mind I'm running FSX-SE with a i7-6700. Thanks.

...therefor I would say HT on and AffinityMask=85. However it is addons that scupper the plan. Use a .bat or an app like Process Lasso to start any addon exe apps on the last two cores.

 

Very sorry if my posts are gobbledegook to you! But unfortunately it's not for me to know what level of experience you are at. In this public forum we are posting for anyone that may come along to read, so a certain amount of presumption must take place.

Share this post


Link to post
Share on other sites

But, SteveW, yourwell delivered reply is gobbledeegook to me!

 

SteveW's posts, interpreted:

 

Steve's extensive research into this topic has determined that FSX:SE will ignore any AffinityMask customization you try to use, and FSX:SE will (correctly) apply the most optimal setting for that feature for you automatically... Behind the scenes being AM=14 for HT-Off, and AM=85 for HT-On. You can safely disregard AffinityMask settings on FSX:SE because it won't abide by your .CFG choices anyway. 

 

Overall, Steve feels that HT-On is the best way to go due to how ancillary computer system drivers and hooks can make use of it. Although one reason to turn HT-Off is to achieve better overclocking, Steve has determined that the higher clock speeds of an HT-Off overclock do NOT end up outweighing the overall performance of HT-On. 

 

Since FSX:SE will use the first core (Core 0) for most of its work, Steve recommends using a batch file or Process Lasso to push any addons (like ActiveSky) to deeper cores - such as the third or fourth (Core 2, 3)... so they interfere less with the sim which is primarily on the first. Personally, I think this would be suited for someone looking to scratch out the absolute best, most efficient system to run the simulator on.

 

Steve knows his stuff. Be like Steve.   ;)

  • Upvote 1

Share this post


Link to post
Share on other sites

Thanks Greg - very kind of you to say that - a proper gent.

 

 

But keeping up with the changes in P3D is far worse, I had a note to recheck the way the latest FSX:SE utilises the AM and never got round to it - it's been out for a year. lol

 

My research comes from developing a test harness for these sims to measure the true throughput capacity, part of which is available in my popular addons.

 

We have to remember that many changes to config settings are so subtle only high resolution test data can determine what's really happening.

 

So if we see comments like "I saw no changes" it's a possibility that the sim is already flat lined with some other setting somewhere.

Share this post


Link to post
Share on other sites

(some CPUs have more than two LPs per core - four per core on a two core AM=113=0111,0001).

 

You kinda lost me there. What CPUs we use FSX on have four logcal cores on each physical core? AM=113 on a dual core with hyperthreading will just assign 1 core. Not a good idea.

The sim decides where the main workers go according to the unmasked LPs - these contain many threads - more than 50. The Jobscheduler starts threads within that AM.

 

The sim might have more than 50 threads but most of them generate very little CPU load. The treads that generate any notable CPU load are:

 

1. The main game thread. It will be assigned the 'first' CPU core assigned with the Afinitymask. If you are just bottlenecked by your CPU this will generate a full core load.

 

2. Texture and terrain loaders. These help loading in the terrain, autogen and ground textures. If you don't have any assigned the main game thread has to do all of that. How many that are created depends on your affinitymask and how many logical CPU cores you have. The amount of Texture and terrain loading threads spawned is the amount of assigned cores in the affinitymask (that fit in the actual logical cores you have) -1. These have a very bursty load. If you are stationary nothing new has to be loaded so they will generate no load. Fly fast and they will generate more load. However every minute the lighting of the ground textures has to be updated so they peak towards a full core load every minute regardless of how fast you fly. The higher LOD setting and the higher resolution scenery/terrain mesh you have the more core load they will generate.

 

 

​3. A thread that reads almost all information needed from your hard drive for the simulator. (Sound files seem to be read off the harddrive by the main thread and a few other files are also accessed by the main thread, hence triggering a sound file might cause a stutter if you don't have an SSD). The load on this thread is very variable and can go from nothing to filling a full core load depending on what scenery you have active. This thread does not get any core assigned by the affinitymask in the cfg. Windows will decide on affinity for it when you start the simulator.

 

4. A sound thread. This generates a small CPU load and is assigned affinity by Windows and not the affinitymask in the cfg. The thread is killed every time the simulator is not the active window any more. And a new sound thread is spawned when the simulator is once again selected as the active window. This new thread will once again get affinity assigned by Windows. But it might be different compared to what it was assigned before.

 

5. A debug thread. Not a lot of CPU load but more than any of the other 50+ threads that are left.

 

 

Windows sheduler doesn't have to adhere to the assigned affinity. It uses it as a guide but most of the time the Main game thread and the texture and terrain loading theads are executed on the cores they have been assigned. But sometimes even they don't. The other threads are regularly being executed on cores outside the affinity assigned to them by Windows.

 

Sorry for all the technical hijack of the tread OP.

Thanks Greg - very kind of you to say that - a proper gent.

 

 

But keeping up with the changes in P3D is far worse, I had a note to recheck the way the latest FSX:SE utilises the AM and never got round to it - it's been out for a year. lol

 

My research comes from developing a test harness for these sims to measure the true throughput capacity, part of which is available in my popular addons.

 

We have to remember that many changes to config settings are so subtle only high resolution test data can determine what's really happening.

 

So if we see comments like "I saw no changes" it's a possibility that the sim is already flat lined with some other setting somewhere.

Fun to reverse engineer the sim right? :smile:

I'm just talking about FSX. Not played around with FSX:SE or P3D.

Share this post


Link to post
Share on other sites

...therefor I would say HT on and AffinityMask=85. However it is addons that scupper the plan. Use a .bat or an app like Process Lasso to start any addon exe apps on the last two cores.

 

Very sorry if my posts are gobbledegook to you! But unfortunately it's not for me to know what level of experience you are at. In this public forum we are posting for anyone that may come along to read, so a certain amount of presumption must take place.

Hi Steve, I hope I didn't come across as dismissive to your reply. I always appreciate the time people kindly take to offer advice on the forum. The gobbledeegook reference was simply aimed at my own ignorance  :smile:

 

 

SteveW's posts, interpreted:

 

Steve's extensive research into this topic has determined that FSX:SE will ignore any AffinityMask customization you try to use, and FSX:SE will (correctly) apply the most optimal setting for that feature for you automatically... Behind the scenes being AM=14 for HT-Off, and AM=85 for HT-On. You can safely disregard AffinityMask settings on FSX:SE because it won't abide by your .CFG choices anyway. 

 

Overall, Steve feels that HT-On is the best way to go due to how ancillary computer system drivers and hooks can make use of it. Although one reason to turn HT-Off is to achieve better overclocking, Steve has determined that the higher clock speeds of an HT-Off overclock do NOT end up outweighing the overall performance of HT-On. 

 

Since FSX:SE will use the first core (Core 0) for most of its work, Steve recommends using a batch file or Process Lasso to push any addons (like ActiveSky) to deeper cores - such as the third or fourth (Core 2, 3)... so they interfere less with the sim which is primarily on the first. Personally, I think this would be suited for someone looking to scratch out the absolute best, most efficient system to run the simulator on.

 

Steve knows his stuff. Be like Steve.   ;)

 

Thanks Greg, sorted. I'll leave hyperthreading on and let allow FSX-SE to take care of things.  

Share this post


Link to post
Share on other sites

You kinda lost me there. What CPUs we use FSX on have four logcal cores on each physical core? AM=113 on a dual core with hyperthreading will just assign 1 core. Not a good idea.

 

Fun to reverse engineer the sim right? :smile:

 

Not sure what you are implying, I'm not reverse engineering any software - thank you. Also google xeon for understanding the number of LPs per core. can be more than two. So the point I made for a four LPs per core is perfectly correct if you check it more carefully. 

Share this post


Link to post
Share on other sites

Not sure what you are implying, I'm not reverse engineering any software - thank you. Also google xeon for understanding the number of LPs per core. can be more than two. So the point I made for a four LPs per core is perfectly correct if you check it more carefully. 

 

Given what you said:

We have to remember that many changes to config settings are so subtle only high resolution test data can determine what's really happening.

 To me changing config settings and testing to figure out what is really happening is reverse engineering. It might not be the 100% correct meaning of the word (English is not my first language). Nothing bad implied.

 

I still can't understand what CPU you mean we can use for flightsim that has 4 threads per core? The only Xeon with 4 threads per core I'm aware of is the Xeon Phi. Whilst its an x86 architecture you can't just run flightsim on it.  What have I missed?

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