Comment 7 for bug 320813

Revision history for this message
Martin Olsson (mnemo) wrote : Re: with EXA compiz animations cause temporary freezes

This is sort of unrelated to the bug but yesterday evening bryce, timo and some other folks discussed the fact that ubuntu now has vblank waiting enables. I've no idea what this really means but as far as I understood this means that for instance in glxgears will drastically reduce it's FPS because it knows that your screen can't show more than 75Hz anyway or so. A very simplified explanation of why this is done is because it taxes the CPU less and thus saves power.

Now, back to this bug. Since these temporary freezes sometimes lasts several seconds on my G45 quad core 2.6GHz I was able to attach gdb to X during the freeze using ssh from another machine. What I found was that the X server had this stack:

(gdb) bt
#0 0x00007f7fa26eadd7 in ioctl () from /lib/libc.so.6
#1 0x00007f7fa14d1464 in drmWaitVBlank () from /usr/lib/libdrm.so.2
#2 0x00007f7f9017a00e in ?? () from /usr/lib/dri/i965_dri.so
#3 0x00007f7f9017a233 in driWaitForVBlank () from /usr/lib/dri/i965_dri.so
#4 0x00007f7f90182189 in intelSwapBuffers () from /usr/lib/dri/i965_dri.so
#5 0x00007f7f9017a993 in ?? () from /usr/lib/dri/i965_dri.so
#6 0x00007f7fa1b2bb8f in __glXDRIdrawableSwapBuffers (basePrivate=0x15e1000) at ../../glx/glxdri.c:251
#7 0x00007f7fa1b1fbd6 in __glXDisp_SwapBuffers (cl=0xf36110, pc=<value optimized out>) at ../../glx/glxcmds.c:1436
#8 0x00007f7fa1b22ea2 in __glXDispatch (client=0xfb6280) at ../../glx/glxext.c:523
#9 0x000000000044e234 in Dispatch () at ../../dix/dispatch.c:437
#10 0x0000000000433c0d in main (argc=10, argv=0x7fffacb10968, envp=<value optimized out>) at ../../dix/main.c:383

For this reason I think it would be an interesting experient to disable this "wait for vblank" feature in drirc and see if these temporary freezes will go away.