#231 Freeze on Dual G4 under GLX stress

X server (105)

When many calls to glFlush (X_GLsop_Flush) occur in
a short period (~256 glFlush/frame at 30fps), the next
call to X may freeze XDarwin for several hundred

In our application, this occurs every second on average
with a 50% variance.

One client side stack during the freeze is below. The
particular X function that freezes is not relevant. What is
common is that select() will block on the X call following
a series of glFlush calls.

TRCoords.c: XTranslateCoordinates (wt_dpy, s->shell,
root, 0, 0, &x, &y, &child);
XlibInt.c: _XReply (dpy, (xReply *)&rep, 0, xTrue)
XlibInt.c: (void) _XRead(dpy, (char *)rep, (long)SIZEOF
XlibInt.c: _XWaitForReadable(dpy)
XlibInt.c: result = Select(highest_fd + 1, &r_mask,

During the freeze, CPU usage drops to zero.

The behaviour occurs on Dual G4 systems and does not
occur when one CPU is disabled. It recurs if the CPU is

Behaviour occurs in all XDarwin version from 1.1 up to
and including 1.12a.2.

Other non-X OpenGL applications running imultaneously
are not affected by the freeze. Multiple instances of the
affected app freeze asynchronously. Note that there are
no (or very few) intervening calls between the 256
glFlush calls. Removing the glFlush calls eliminate the

Our application works on many other platforms under
the X Window System without exhibiting this behvaiour.
The platforms include: SGI Irix, HP/UX, IBM AIX &
Linux, Sun Solaris, and PC Linux, among others.


  • Torrey T. Lyons

    Torrey T. Lyons - 2002-12-10
    • milestone: 102991 --> Other
    • assigned_to: nobody --> gparker
  • Torrey T. Lyons

    Torrey T. Lyons - 2002-12-10

    Logged In: YES

    Throwing this over to Greg to see if he has any ideas.

  • Torrey T. Lyons

    Torrey T. Lyons - 2003-07-21

    Logged In: YES

    Does this problem still occur on XFree86 4.3.0 (XDarwin 1.2.0) or
    Apple's X11?

  • Anonymous - 2003-07-22

    Logged In: YES

    We could avoid the issue by removing the extraneous glFlush
    calls. Therefore, we did not test for the problem behaviour
    either under 4.3.0 or X11.

    At some point, I will remove the workaround and see if the
    problem still exists.

    Our assumption has been that the problem occurs due to a
    latent race condition that is exacerbated by the dual

  • Torrey T. Lyons

    Torrey T. Lyons - 2003-12-16

    Logged In: YES

    In Apple's X11 and XFree86 4.4.0 the GLX support has changed
    quite a bit from 4.3.0 and bears almost no resemblence to 4.2.x
    which this bug was noticed under. Closing. Please repost a bug
    report if this bug can be duplicated on 4.4.0 or Apple's X11.

  • Torrey T. Lyons

    Torrey T. Lyons - 2003-12-16
    • status: open --> closed-out-of-date

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks