Jump to content
Sign in to follow this  
AviatorMoser

A Frame-Time Analysis of P3D v3 -- Effects of CPU Affinity, Frame Lock, and HT

Recommended Posts

Still puzzled by HT problems? Here's one way to get better results with HT Off on a four core, than with HT On and AM=85=(01,01,01,01) is likely if you have a program, starts on core zero, and with HT disabled its second thread hits core 1, but with HT enabled it will hit the second LP of core zero. 

 

Would it apply to Ezdok Camera program?

 

Thanks,

Dirk.

Share this post


Link to post

The jobscheduler will direct processes of any exe onto any processors showing least work. The only way is to test.


Steve Waite: Engineer at codelegend.com

Share this post


Link to post

Following this thread

thanks

RMM

Share this post


Link to post

The jobscheduler will direct processes of any exe onto any processors showing least work. The only way is to test.

Does this include the OS?

Share this post


Link to post

 

 


I might upgrade, but is there anything I can do to avoid?

 

Without upgrading my suggestion would be to start with a clean install, leaving the config untouched. Then see how the fps are with a stock aircraft and a stock airport. They should be better than 10-15. Add only one region from ORBX and try again. Then add a more complex aircraft. Stay away from ORBX Vector and don't install more than one add-on at a time. While your system is not ideal you should be able to fly so my guess is you are throwing to much at it.


Hans

Share this post


Link to post

Does this include the OS?

Yes, the Windows jobscheduler places all threads as it requires and moves threads around if it needs to, other than threads that have specially asserted an affinity, these stay put like the main thread jobs of P3D.

 

...It may be interesting to note that when we look in the F2 setup for the motherboard Intel CPUs often it may say that hyperthreading is operating system dependent, may say enable for Windows not for Linux. The Windows O/S takes advantage of HT, but in general the apps, unless specially written, don't know or care about HT or the jobscheduler. P3D does not care if HT is on or off it just makes a thread job per processor and allows us to control it properly with the AffinityMask setting, it does this because it is a professional way of doing it. FSX and FSX-SE are different and require more care and knowledge of their threading models with setting affinity especially on HT enabled systems (in fact FSX-SE ignores the user affinity setting and must be set with another app).


Steve Waite: Engineer at codelegend.com

Share this post


Link to post

I have an i7-5820K (6 cores, HT on).  Plus nVidia 960 with 4GB.

 

I always set the process priority to "high" & I have the frame rate internally locked to 40, with fairly modest scenery detail settings.  Despite this, I often see blurred textures.

 

Would I see any benefit from using AM, if so, what setting?

 

Thanks,

Share this post


Link to post

hello, I used to use these settings, but since I updated the Nvidia 368.22 , P3D software not working as before and have lower flow , I want to know if someone else is in the same situation as me

Share this post


Link to post

Hello

 

Just a question

 

If you use some programs on a network laptop, what about the am in p3d?

Should i use my cpu in ht on or OFF?

Thanks


Frédéric Giraud

Share this post


Link to post

nobody can answer?

 

P3D works well without AM and no HT. Later, once you have your system settled down, then you can think more closely about adding an optional AM or HT for a slight boost in performance maybe.

Share this post


Link to post

I personally see the "smoothest" P3D with HT off and no AM.

With HT off I can crank the CPU up to 4.7 GHz, with HT on I get around 4.4 GHz with even higher temps.

 

Single core performance is in my eyes still the key performance figure for P3D.

 

But it sure depends on other factors. A "magic setting" for HT and AM is not existing.

Share this post


Link to post

Thanks for a very interesting thread! Just a question, since I'm a total noob when it comes to this degree of technicality:

AM=85 (HT on) means that only the 4 physical cores are used, and not the additional 4 logical ones, right? Why is that?

Why isn't AM=255 the better option?

 

This is of course given a 4 core i7 processor with HT enabled.


Andreas Stangenes

http://www.youtube.com/user/krsans78
Add me on gamertag: Bullhorns78

Share this post


Link to post

Well, you got four cores and each of those pretends to be two. Each pair of logical processors are running on one core. Now say you got 8 equal threads and HT disabled, for argument's sake the jobscheduler puts two on each core. The CPU runs each thread a little and switches to the other and runs that for a little while and switches back the first and so on. Each core appears to run two threads simultaneously.

 

Now turn on HT and say the jobscheduler puts one on each logical processor, that's still two to each core, same as our HT disabled. Only difference is that there's less switching time consumed by the two threads as each is switched on that core, still just one core but that's what HT does, improve the switch time.

 

Extend that thinking to P3D, which counts the number of processors (HT disabled sees 4, HT enabled sees 8), and makes a job on each processor. So with HT disabled it makes four jobs, one per core, but with HT enabled it makes eight jobs, two per core.

 

AM=85=01,01,01,01 unmasks only one logical processor per core, so the sim sees four processors, one per core, and runs just like it does with HT disabled. HT disabled no AM is equivalent to HT enabled AM=85 (or any mask that unmasks one of each core e.g. 170).

 

Even after booting up Windows can be running in excess of 200 threads so whatever we do there will be stuff running on all those processors. Most of them are dormant during the running of the sim. But when any run on the same core it makes sense to have HT enabled.

 

The sim threads may want to gain maximum throughput. So if the sim starts two threads on the first core processors zero and one, then it's defeated the object of splitting it out over the cores, masks with alternate ones (enabled) prevent that.

 

We can intensify the use of cores by allowing P3D to make two jobs per core with HT enabled. However, we don't allow the first and second jobs on the same core, we mask one of the processors of the first core.

 

The first job requires maximum core throughput so keep other processes including the sim's own subprocesses and addon exe's threads off of it too. An AM=253=11,11,11,01 allows the first sim job to run on core zero on the right most 01. Then there are six more jobs two on each of cores 1, 2 and 3. This intensifies scenery loading at a small cost to ultimate fps rate and stability if we allow more than four jobs. Since v3.2 this performance with more than four jobs is better.

 

The main thing with 85 or 253 is that they will more or less appear to run the same, but they have *vastly differing characteristics* as the sim loading rises. Paired processes per core maximum capable throughput is only half when both are asking for more than half the capacity of the core. Hence the better performance on 8 core no AM HT disabled CPUs.

 

The stability of the sim (fps) in running is often improved simply by having a bunch of settings that flat-line the sim performance to a more consistent framerate, but we can do that irrespective of how any kind of AM works the sim. Unfortunately this effect is often thought to be a sign of increased performance.

 


Steve Waite: Engineer at codelegend.com

Share this post


Link to post

I have a 2600k @ 4,6Ghz. HT is off but can enable ir. What AM is good for me?


José Fco. Ibáñez /// i7 6700k (Delid) @ 4,6 Ghz /// Asrock Z170 OC Formula /// 16GB RAM G.Skill Ripjaws V 3200 /// GTX 1070 Founders Edition 8GB /// LG 27UD58 4K 27' // OCZ Vertex 4 SSD (X-Plane 10) & SAMSUNG 850 EVO SSD (P3D V3) /// Windows 10 Pro x64

 

sig_FSL-By-Wire.jpg

Share this post


Link to post

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...