[lkml]   [1999]   [Apr]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: Linus on Linux, Apache and Threads

    On 26-Apr-99 Stephen C. Tweedie wrote:
    > That's not the point. Many server systems do use a single
    > demultiplexing process with multiple worker threads.
    > Right now, they typically use something like pipes to share the
    > work
    > amongst worker threads. Threads pick the data up in FIFO order
    > when new
    > work enters the queue. The problem is that every mechanism we have
    > for
    > this will wake up ALL idle worker threads in the kernel: only one
    > will
    > actually succeed in grabbing the message, but the others will still
    > consume kernel-mode CPU time.

    Can I just get some clarification here. pthread_cond_signal is
    defined as waking *one* thread, thus:

    pthread_cond_signal restarts one of the threads that are
    waiting on the condition variable cond. If no threads are
    waiting on cond, nothing happens. If several threads are
    waiting on cond, exactly one is restarted, but it is not
    specified which.

    Are you saying that the kernel will in fact wake up *all* the threads
    (either just internally, or in actuality)?


    E-Mail: Tony Gale <>
    Vote for ME -- I'm well-tapered, half-cocked, ill-conceived and TAX-DEFERRED!

    The views expressed above are entirely those of the writer
    and do not represent the views, policy or understanding of
    any other person or official body.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:51    [W:0.020 / U:26.280 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site