Jump to content
Sign in to follow this  
dutton98

VSync and triple buffering!

Recommended Posts

So, Steve, should we just use the VSync control in P3D and run the NCP Vsync as "Use the 3D Application Setting" or "On" ? I have been using "On" (and the P3D setting as "On" also) and it seems to run fine, but based on what I am now reading, I'm not sure that is correct.

 

Thanks,

Jeff

Default NCP "Use the 3D Application Setting"

Use P3D display settings VSync and TBuffer.


Steve Waite: Engineer at codelegend.com

Share this post


Link to post

Thanks again, Steve.  I'll make that change.

 

Jeff


Jeff Smith

 

System: i9-9900K@5.0GHz., ASUS Maximus XI Hero MB, 32 GB 3200 Hyper-X RAM, Corsair HX1000i PSU, Cooler Master ML360R RGB, EVGA RTX 3080Ti FTW3, (2) Samsung 860 500GB SSD for Windows 10 Pro and sim, (2) M.2 NVMe 2TB, (2) WD Black 4TB HD for data, Samsung 65" 4K curved monitor @ 30Hz. (Currently running VSync, TB , Unlimited),YOKO+ yoke, VF TQ6+,TPR pedals, Logitech Multi, Switch, and Radio Panels

Software:  P3Dv4.5HF3 Pro, Ultimate Traffic Live, ASP3D, ASCA, ORBX, Fly Tampa, GSX/GSX2, PMDG, A2A, Just Flight, Milviz, Carenado, Majestic.

On other computer: P3D v3.2.3, My Traffic 6.0a, PMDG, ORBX, A2A, Captain Sim , iFly, Flight 1, Flysimware, Just Flight, Milviz, Carenado

Share this post


Link to post

 

 


P3D is an elaborate desktop window in fullscreen mode, but FSX in fullscreen uses the Windows exclusive mode.

 

So Thanks Steve for pointing that difference. As I slept on it all the night, I decided this morning to change my desktop to Windows 7 Aero theme, and I can say that everything is now a lot better.

Strange ?

 

Regards

Claude


Claude Troncy

Share this post


Link to post
Hi Steve and all. I read this comment on this website. http://www.gatwick-fsg.org.uk/affinitymask.aspx?SubMenuItem=utilties
 
Please be aware that P3D V2.x & V3.x by default will use all Cores and most importantly all Threads also on CPU's that have Hyper Threading enabled. On machines with four or more cores, P3D will dedicate logical core #0 thread #0 for rendering tasks

 

 
Accordingly this, values like 84 or 116 AM have an adverse effect on the simulator, and leaving the core zero out.
All a bit confusing. I would like to know your opinion.
Thank you.

Share this post


Link to post

Yes confusing. If we don't mask P3D, it will make 8 jobs on a 4 core with HT, and 16 jobs on a 8 core with HT. Not good, four jobs is key. Unmasked the sim makes jobs on every LP and so it will make the first job on LP0, the first LP it finds. If we use 84 (3 jobs) or better 116 (4 jobs), the first job will be made on LP2, avoiding LPs 0 and 1 on core zero. With a four core we can allocate three cores to the sim and leave core zero free for the jobscheduler to target with other processes. What Gatwick calculator does is avoid allocating two jobs on the first core. Read any of my posts on HT and AM.


Steve Waite: Engineer at codelegend.com

Share this post


Link to post

Chocolate ice cream doesn't work for me - ONLY MONEY! lol


Steve Waite: Engineer at codelegend.com

Share this post


Link to post
Ok Steve. Now I have the things a little clearer.

At the end I terminare learning something.  :wink:

Share this post


Link to post

Yes confusing. If we don't mask P3D, it will make 8 jobs on a 4 core with HT, and 16 jobs on a 8 core with HT. Not good, four jobs is key. Unmasked the sim makes jobs on every LP and so it will make the first job on LP0, the first LP it finds. If we use 84 (3 jobs) or better 116 (4 jobs), the first job will be made on LP2, avoiding LPs 0 and 1 on core zero. With a four core we can allocate three cores to the sim and leave core zero free for the jobscheduler to target with other processes. What Gatwick calculator does is avoid allocating two jobs on the first core. Read any of my posts on HT and AM.

Wait a minute because you now have me more confused, are you saying that you should not use, this is as an example with HT on, (* denotes use), a 6 core, 01-**-45-**-**-** and use 01-*3-*5-*7-*9-*11


Nick Sciortino

 

Share this post


Link to post

Wait a minute because you now have me more confused, are you saying that you should not use, this is as an example with HT on, (* denotes use), a 6 core, 01-**-45-**-**-** and use 01-*3-*5-*7-*9-*11

No.

 

With a six core you could apply a mask AM=1360=01,01,01,01,00,00=4,6,8,10, giving four full cores away from addons. Addon exes will naturally start on LP0, and go on to fill, LPs 1, 2, and 3. Without the mask, P3D would go on to fill all LPs from zero to eleven.

 

Of course, it's up to the jobscheduler what happens when the exe addons are making more threads and it comes to LP5. At LP5 the sim is making full use of the core. You will see activity nearing 100% on LP4, and near the floor on LP5, that's good news. The jobscheduler will ignore core 2 (LPs 4 and 5), and have a look at core 3, and so on.

 

If you apply to that 6 core HT enabled, an AM=340=00,01,01,01,01,00, you've moved the chain of cores used by P3D toward the front. This means that after LPs 0 and 1 are filled, the jobscheduler is already inspecting cores of the sim. In this way the system resources and addon exes are given slightly more advantage, than P3D (or FSX).

 

 

If you've got an 8 core, AM=21760 leaves a block of four cores ahead of the sim to soak up everything your addons can throw at it.

 

 

With a four core we have a dilemma; where do we put the addons if we want four cores? We can leave a core (core zero) and push the sim up onto three cores. We can do that with 84=01,01,01,00. But 84 only makes three jobs. Instead we can apply the AM=116=01,11,01,00, that bunches jobs 2 and 3 together on a core, leaving the main UI job free to a whole core. This shows an improvement over 84.

 

We can also run the sim on all four cores with AM=85=01,01,01,01, but we would like to make sure we don't have any addons start on core zero (LPs 0 and 1) before the sim is fully running, otherwise the jobscheduler will place threads on core zero, and the main job will sawtooth, producing the stutter.

  • Upvote 1

Steve Waite: Engineer at codelegend.com

Share this post


Link to post

No.

 

With a six core you could apply a mask AM=1360=01,01,01,01,00,00=4,6,8,10, giving four full cores away from addons. Addon exes will naturally start on LP0, and go on to fill, LPs 1, 2, and 3. Without the mask, P3D would go on to fill all LPs from zero to eleven.

 

Of course, it's up to the jobscheduler what happens when the exe addons are making more threads and it comes to LP5. At LP5 the sim is making full use of the core. You will see activity nearing 100% on LP4, and near the floor on LP5, that's good news. The jobscheduler will ignore core 2 (LPs 4 and 5), and have a look at core 3, and so on.

 

If you apply to that 6 core HT enabled, an AM=340=00,01,01,01,01,00, you've moved the chain of cores used by P3D toward the front. This means that after LPs 0 and 1 are filled, the jobscheduler is already inspecting cores of the sim. In this way the system resources and addon exes are given slightly more advantage, than P3D (or FSX).

The reason I had listed the example above is I purchased Lasso and without any changes to P3, this means no AM, I did a few flights using NGX and payware scenery and kept tabs on the CPU within Lasso. I then changed the set order (I think this is called that) to utilize cores 00 23 00 6-11 and move every thing else to 01 and 45.


Nick Sciortino

 

Share this post


Link to post

When HT is enabled one core looks like two cores to the app. It is still only one core, so we unmask, or utilise, alternate LPs to avoid bunching jobs onto a core. Two jobs looking for 100% of a core, on the same core, but on alternate LPs, each get 50% and the graphs show them getting 100%. In order to understand P3D multi threading, it is helpful to look into how it splits as more LPs are unmasked. After inspecting that, it can be shown why the three core four LP AM=116 configuration outperforms the three core three LP AM=84 configuration.


Steve Waite: Engineer at codelegend.com

Share this post


Link to post

No.

 

With a six core you could apply a mask AM=1360=01,01,01,01,00,00=4,6,8,10, giving four full cores away from addons. Addon exes will naturally start on LP0, and go on to fill, LPs 1, 2, and 3. Without the mask, P3D would go on to fill all LPs from zero to eleven.

 

Of course, it's up to the jobscheduler what happens when the exe addons are making more threads and it comes to LP5. At LP5 the sim is making full use of the core. You will see activity nearing 100% on LP4, and near the floor on LP5, that's good news. The jobscheduler will ignore core 2 (LPs 4 and 5), and have a look at core 3, and so on.

 

If you apply to that 6 core HT enabled, an AM=340=00,01,01,01,01,00, you've moved the chain of cores used by P3D toward the front. This means that after LPs 0 and 1 are filled, the jobscheduler is already inspecting cores of the sim. In this way the system resources and addon exes are given slightly more advantage, than P3D (or FSX).

 

 

If you've got an 8 core, AM=21760 leaves a block of four cores ahead of the sim to soak up everything your addons can throw at it.

 

 

With a four core we have a dilemma; where do we put the addons if we want four cores? We can leave a core (core zero) and push the sim up onto three cores. We can do that with 84=01,01,01,00. But 84 only makes three jobs. Instead we can apply the AM=116=01,11,01,00, that bunches jobs 2 and 3 together on a core, leaving the main UI job free to a whole core. This shows an improvement over 84.

 

We can also run the sim on all four cores with AM=85=01,01,01,01, but we would like to make sure we don't have any addons start on core zero (LPs 0 and 1) before the sim is fully running, otherwise the jobscheduler will place threads on core zero, and the main job will sawtooth, producing the stutter.

 

....and I finally understand.  You have not said it here but I am guessing no AM in the cfg (default) is 85 and then you have get the other exe's from addons off core one using the .bat file you linked to on another thread.


Mark W   CYYZ      

My Simhttps://goo.gl/photos/oic45LSoaHKEgU8E9

My Concorde Tutorial Videos available here:  https://www.youtube.com/user/UPS1000
 

 

Share this post


Link to post

Yes that's it. But P3D (and FSX) will not use 85, or 170, they will use AM=0.

 

AM=0 is a special case, the software will interpret this number as all cores or LPs unmasked.

 

So in fact on a four core with HT, AM=0=255, and on four core without HT AM=0=15.

 

So we can say use no AM with the four core no HT, or with a dual core HT on or off. But with the four core HT on, no AM means AM=0=255=11,11,11,11 - we get eight jobs, each pair contending for throughput of their core.

  • Upvote 1

Steve Waite: Engineer at codelegend.com

Share this post


Link to post

Hi Steve,

 

Firstly thank you for all your contributions here. I read your recent comments regarding setting the AM for an i7-5960X in the prepar3d.cfg file:

 

[JOBSCHEDULER]
AffinityMask=21760
 
I'm surprised at this recommendation, as this very setting turns my P3Dv3 into a stutterfest. In fact I have found that using any form of AM setting in the cfg seems to be detrimental to performance.
 
I use EasyToolz to set AM externally and have turned off all HT cores along with the very first core too. This seems to deliver the best performance on my system - i7-5960X CPU and GTX 980 GPU.
 
Using a 21760 type setting in EasyToolz also caused terrible stutters.
 
Cheers,
 
Jerome

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