Re: [PATCH] Lightweight userspace semaphores...

From: Linus Torvalds (torvalds@transmeta.com)
Date: Mon Feb 25 2002 - 12:44:09 EST


On Mon, 25 Feb 2002, Alan Cox wrote:
>
> Any kernel special cases it adds will be unswappable because they are in
> kernel space (not the semaphores here - we want them to be swappable and
> they can be)

Alan, wake up!

I'm talking about anonymous semaphores, the kernel implementation can just
map a normal anonymous page there.

On 99.9% of all machines out there, you can have semaphores in perfectly
normal memory.

> When you create a shared mapping by passing -1 to mmap we do

Why are you talking about shared mappings?

The most common case for any fast semaphores are for _threaded_
applications. No shared memory, no nothing.

                Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Feb 28 2002 - 21:00:16 EST