Jump to content

Sign in to follow this  
Rockliffe

Advice on hyperthreading

Recommended Posts

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!


Howard
P3Dv4, Asus Z170-A MB, i7-6700 Skylake @ 4.5ghz, Asus GTX1080ti 11Gb GPU, 16gb RAM@3200Mhz, SSD/1Tb+P3D.v4.4, SSD/500Gb+OS, Western Digital 1Tb HD + Storage, Ocz 750 PSU, Philips BDM4350UC 43" 4K IPS, 2 x 17" Dell @ 1920x1200. PFC Yoke, Warthog throttle system, MFG Crosswind rudder pedals, Saitek switch and radio panels, VRinsight Boeing 2 MCP.



Banner_FS2Crew_Supporter.jpg

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


Luke Kolin

I make simFDR, the most advanced flight data recorder for FSX, Prepar3D and X-Plane.

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.


Steve Waite: Engineer at codelegend.com

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.


Steve Waite: Engineer at codelegend.com

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.


Steve Waite: Engineer at codelegend.com

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.  


Howard
P3Dv4, Asus Z170-A MB, i7-6700 Skylake @ 4.5ghz, Asus GTX1080ti 11Gb GPU, 16gb RAM@3200Mhz, SSD/1Tb+P3D.v4.4, SSD/500Gb+OS, Western Digital 1Tb HD + Storage, Ocz 750 PSU, Philips BDM4350UC 43" 4K IPS, 2 x 17" Dell @ 1920x1200. PFC Yoke, Warthog throttle system, MFG Crosswind rudder pedals, Saitek switch and radio panels, VRinsight Boeing 2 MCP.



Banner_FS2Crew_Supporter.jpg

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. 


Steve Waite: Engineer at codelegend.com

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

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.

Not at all Howard, you're welcome. As I said previously my comments on the public forums are aimed at a general diversity of experience. When a lot of stuff is already described in a discussion I'll usually skip grounding to the more technical content, and readers can find out more at their own pace and ask question on that forum or PM me. All the best.

 

Given what you said:

 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?

Maybe you can re-read my comment to straighten yourself out. The mention of four LPs per core was an example, that's not a recommendation for flight simmers.


Steve Waite: Engineer at codelegend.com

Share this post


Link to post
Share on other sites

The answer is that there is no CPU with 4LPs per core you can run FSX or P3D on now. Just in case someone is trying to follow the conversation.

Share this post


Link to post
Share on other sites

The answer is that there is no CPU with 4LPs per core you can run FSX or P3D on now. Just in case someone is trying to follow the conversation.

No one suggested you can. Please go back and read the discussion more carefully.


Steve Waite: Engineer at codelegend.com

Share this post


Link to post
Share on other sites

Thanks fellas. What I will do I think, are some tests of my own. I will be interested in seeing the results  :smile:


Howard
P3Dv4, Asus Z170-A MB, i7-6700 Skylake @ 4.5ghz, Asus GTX1080ti 11Gb GPU, 16gb RAM@3200Mhz, SSD/1Tb+P3D.v4.4, SSD/500Gb+OS, Western Digital 1Tb HD + Storage, Ocz 750 PSU, Philips BDM4350UC 43" 4K IPS, 2 x 17" Dell @ 1920x1200. PFC Yoke, Warthog throttle system, MFG Crosswind rudder pedals, Saitek switch and radio panels, VRinsight Boeing 2 MCP.



Banner_FS2Crew_Supporter.jpg

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.
  • Donation Goals

    AVSIM's 2020 Fundraising Goal

    Donate to our annual general fundraising goal. This donation keeps our doors open and providing you service 24 x 7 x 365. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. We reset this goal every new year for the following year's goal.


    28%
    $7,035.00 of $25,000.00 Donate Now
×
×
  • Create New...