PDA

View Full Version : profiling a compositing window manager - glXSwapBuffers performance



Triangle
04-27-2015, 05:40 AM
I examine a Compiz performance when it draws desktops using expo plugin. VSync in Compiz and nvidia-settings is disabled ( I run glxgears to test if vsync is disabled). In Compiz I measure a time this way:



paint()
{
//get time
//all opengl commands
glFlush();
glFinish();
//get time
//calculate paint time

//get time
glXSwapBuffers (mDpy, mOutput);
glFlush();
glFinish();
//get time
//calculate sync/swap time
}


When I run 4 opengl windows I get from Compiz following times:

- average frame paint time: 29 ms
- average frame sync/swap time: 28 ms

Those OpenGL windows have internal render speed about 38 fps. Why glXSwapBuffers in Compiz is so slow ?
How to explain that ?