Performance problem of SDL_RenderPresent() on Windows

Hello everyone! Does anyone know about performance of SDL_RenderPresent()?

When I hit F5(Start debugging) in Visual Studio, every SDL_RenderPresent()
takes about 15ms, but when I run my program in command Prompt,
SDL_RenderPresent() takes 15ms on the first hundreds of frames, after that
it takes up to 35ms, and the screen freezes. The problem remains on both
DEBUG and RELEASE version of the application. Any idea? Thanks!

15ms? That sounds like vsync to me (60Hz is 16?ms per frame, for reference).

No idea about the 35ms one though, other than Windows doing something
in the background when launching from console that makes it drop
framerate (but even then I’d assume something like that would
eventually sort it out itself).

2013/10/10, SouthWolf <wp.southwolf at gmail.com>:> Hello everyone! Does anyone know about performance of SDL_RenderPresent()?

When I hit F5(Start debugging) in Visual Studio, every SDL_RenderPresent()
takes about 15ms, but when I run my program in command Prompt,
SDL_RenderPresent() takes 15ms on the first hundreds of frames, after that
it takes up to 35ms, and the screen freezes. The problem remains on both
DEBUG and RELEASE version of the application. Any idea? Thanks!

Hello everyone! Does anyone know about performance of SDL_RenderPresent()?

When I hit F5(Start debugging) in Visual Studio, every SDL_RenderPresent()
takes about 15ms,

Sounds about normal with retrace sync enabled.

but when I run my program in command Prompt,
SDL_RenderPresent() takes 15ms on the first hundreds of frames, after that
it takes up to 35ms, and the screen freezes. The problem remains on both
DEBUG and RELEASE version of the application. Any idea? Thanks!

Memory leak?

Too much bloatware (antiviruses etc) running? (I thought my new
"budget" Win8 laptop was just too slow for Kobo II until I removed the
OEM nonsense that was running several processes at 25+% most of the
time…)

Doing frequent system calls that get you penalized with lower priority?

Oh, wait… Are you printing stuff to stdout/stderr? That causes
massive performance issues on some systems; Windows and others.On Fri, Oct 11, 2013 at 4:12 AM, SouthWolf <wp.southwolf at gmail.com> wrote:


//David Olofson - Consultant, Developer, Artist, Open Source Advocate

.— Games, examples, libraries, scripting, sound, music, graphics —.
| http://consulting.olofson.net http://olofsonarcade.com |
’---------------------------------------------------------------------’