Yes, and I'm really not interested in it. Linux's kernel threads have
the advantage of being able to take advantage of multiple processors,
not block on hard-drive accesses, not block on paging requests, and so
on. Pthreads can't do that.
> > 2) I have heard that the new mmap based malloc in libc is thread safe
> > and doesn't depend on usermode locks to be so. Is this true?
>
> I doubt that: it certainly subdivides mmaped blocks, and that would require
> locking.
Hardly the definitive answer I was looking for ;)
> > 3) Are there any user-mode locking functions available? Preferably ones
> > that are guaranteed atomic and FIFO?
>
> I'm having a hard time imagining a strictly-usermode queueing lock.
I must have asked the question badly to warrent such a silly reply. I
was meaning to ask if there were any kernel functions (syscalls) which
implemented user-mode locking in a way that is guaranteed 1) atomic
and 2) FIFO.
I'll post Linus's code snippet to the list later today or tomarrow.
Christopher