Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 08-04-08, 11:52 PM   #13
twbos
Registered User
 
Join Date: Jul 2008
Posts: 14
Default Re: glXSwapBuffers latency/dropped frames

That is interesting. I still have the problem. I installed one machine from scratch with ubuntu and just used ext2 and shut everything thats not needed off, and the delay shrunk to a little under 6ms, but it still occurs at the very same times. This is even the case when nothing but glXswapbuffers is called, i.e. no other OpenGL commands are ever called.

Thomas

PS: plot for timing is attached, x-axis is n-th swap call, y axis is deviation from nominal frame rate in nano-seconds, i.e. 1e6 = 1 millisecond.

Update: I can bring the lag down to less than 3 ms, I guess its like savali's then, when I add a glFlush before glXSwapBuffers, the lag occurs however twice as often then.
Attached Thumbnails
Click image for larger version

Name:	glx_timing.png
Views:	204
Size:	7.3 KB
ID:	32497  
twbos is offline   Reply With Quote
Old 08-05-08, 01:05 AM   #14
twbos
Registered User
 
Join Date: Jul 2008
Posts: 14
Default Re: glXSwapBuffers latency/dropped frames

Okay, the code on my website and what savali used had the glFlush() already. With that I get the same timing as savali. See attached figure. Half the lag, but twice as often.
Attached Thumbnails
Click image for larger version

Name:	glx_timing_glflush.png
Views:	177
Size:	10.6 KB
ID:	32498  
twbos is offline   Reply With Quote
Old 08-05-08, 04:43 AM   #15
savali
Registered User
 
Join Date: Apr 2005
Posts: 9
Default Re: glXSwapBuffers latency/dropped frames

Now those graphs look similar. Graph for my data is included.

So for my plot, 1 sample is 1 / 85 sec. And if I understand correctly for your data it's 5 / 59.7 sec.
Frequency between your spikes is about 450 samples -> 37.7 sec.

For my "larger" spikes it's about 4500 samples -> 52.9 sec. So we are still in same time scale.

In my machine there are few background processes, so that might be the reason for more uneven data.

But I would definitely like to hear what is causing those large spikes. I think that that's large enough to be noticeable when doing smooth motion on screen.
Attached Thumbnails
Click image for larger version

Name:	glx_swaps2.png
Views:	175
Size:	11.6 KB
ID:	32503  
savali is offline   Reply With Quote
Old 08-05-08, 12:23 PM   #16
twbos
Registered User
 
Join Date: Jul 2008
Posts: 14
Default Re: glXSwapBuffers latency/dropped frames

Uh, another bit of info. The less than 6ms latency with the glFlush() trick only works with kernel 2.6.24. With 2.6.25 or higher the latencies are always between 20 and 95 ms.
twbos is offline   Reply With Quote
Old 08-22-08, 08:26 AM   #17
ZicoTheTux
Registered User
 
Join Date: May 2004
Posts: 182
Default Re: glXSwapBuffers latency/dropped frames

I think I noticed something similar.

Using my own game-engine, VSync manages to make the program shutter a bit in varfious intervals.
I am running a TFT on 60Hz so the Time between Frames should be 16,66666 ms.

Printing out the times sometimes shows this when the program shutters:
Code:
TIME_INFRAME: 17.000000 ms                                      
TIME_INFRAME: 16.000000 ms                                      
TIME_INFRAME: 17.000000 ms                                      
TIME_INFRAME: 17.000000 ms                                      
TIME_INFRAME: 16.000000 ms                                      
TIME_INFRAME: 17.000000 ms
TIME_INFRAME: 17.000000 ms
TIME_INFRAME: 16.000000 ms
TIME_INFRAME: 30.000000 ms
TIME_INFRAME: 3.000000 ms
TIME_INFRAME: 17.000000 ms
TIME_INFRAME: 17.000000 ms
TIME_INFRAME: 16.000000 ms
TIME_INFRAME: 17.000000 ms
TIME_INFRAME: 16.000000 ms
TIME_INFRAME: 17.000000 ms
TIME_INFRAME: 16.000000 ms
TIME_INFRAME: 16.000000 ms
Not sure how to solve that... and I cannot even state when it begun...
ZicoTheTux is offline   Reply With Quote
Old 08-24-08, 06:40 AM   #18
ZicoTheTux
Registered User
 
Join Date: May 2004
Posts: 182
Default Re: glXSwapBuffers latency/dropped frames

Further stuff:

As suggested Powermizer seems to be responsible for this.

I tried all 3 available workarounds:
- Infinite nvidia-settings loop
- Seeting Powerlevel in xorg.conf
- Setting mobile and Powerlevel in modules options

Nothing really helped me out so far - I am not using a notebook, just a Desktop system with a 9600GT. I can get around the problem if I disable the texture caching on my engine so the GPU has more work to do. Then the game runs smooth as butter.
Ironic - isn't it: My game runs choppy because it has so small requirements.

Just a friendly question: Is any Powermizer optimisation planned for the next BETA or stable release? Aaron, Zander?
ZicoTheTux is offline   Reply With Quote
Old 08-24-08, 06:54 AM   #19
Big P
Registered User
 
Join Date: Dec 2004
Posts: 180
Default Re: glXSwapBuffers latency/dropped frames

Quote:
Originally Posted by ZicoTheTux View Post
Nothing really helped me out so far - I am not using a notebook, just a Desktop system with a 9600GT
AFAIK, only mobile chipsets are affected by PowerMizer. In nvidia-settings I have a PowerMizer tab for my 8800GTS G92, but there's only one "Performance Level".
Big P is offline   Reply With Quote
Old 08-24-08, 07:05 AM   #20
ZicoTheTux
Registered User
 
Join Date: May 2004
Posts: 182
Default Re: glXSwapBuffers latency/dropped frames

Same here. I can only pinpoint Powermizer due my GPU load. The more I "give work to the GPU", the less delays between Buffer Swaps I have. I am basically working on an engine from 1995 so even with OpenGL it's not very demanding... And it's the only point where I have those delays like the graphs in page 1 of this thread show. All other OpenGL games I tried use more GPU load and CPU and run pretty smooth as well.

Same delays I experience with some small OpenGL text programs using Doublebuffering. I would like to solve or at least address this problem somehow before I start implementing an intended bottleneck to my app just to run it smooth.
ZicoTheTux is offline   Reply With Quote

Old 08-24-08, 08:05 PM   #21
ZicoTheTux
Registered User
 
Join Date: May 2004
Posts: 182
Default Re: glXSwapBuffers latency/dropped frames

Okay I got it.

Kernel option nopat to disable X86_PAT.

NVIDIA DEVELOPERS, please consider this - would be nice if you can at least summarize this in your docs to help out guys like me in the future.
ZicoTheTux is offline   Reply With Quote
Old 08-26-08, 07:24 PM   #22
twbos
Registered User
 
Join Date: Jul 2008
Posts: 14
Default Re: glXSwapBuffers latency/dropped frames

Actually for me the problem also disappeared after upgrading to 177.68. The nopat makes sense, as in my previous posts I noticed that the issue only started with newer 2.6.26 kernels and also on my website I have evidence that the delays are caused by page allocation. Anyhow with 177.68 the problem vanished even with PAT activated.

Thomas
twbos is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
Counter-Strike skipping frames on a GeForce4 demonized NVIDIA GeForce 7, 8, And 9 Series 8 10-10-02 06:02 PM

All times are GMT -5. The time now is 06:00 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.