At comment about lock position.
authordrepper <drepper>
Fri, 28 Feb 2003 00:34:41 +0000 (00:34 +0000)
committerdrepper <drepper>
Fri, 28 Feb 2003 00:34:41 +0000 (00:34 +0000)
nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S

index 7c27b94..4eebc4b 100644 (file)
@@ -109,7 +109,9 @@ pthread_barrier_wait:
        movl    $SYS_futex, %eax
        ENTER_KERNEL
 
-       /* Release the mutex.  */
+       /* Release the mutex.  We cannot release the lock before
+       waking the waiting threads since otherwise a new thread might
+       arrive and gets waken up, too.  */
        LOCK
        incl    MUTEX(%ebx)
        jng     4f