lkml.org 
[lkml]   [1999]   [Feb]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Linux Driver - Select Implementation!

Charles Cazabon writes:

> This thundering herd problem can be solved in userland, if I am not
> mistaken. From what I've read, Apache solves this problem by having
> a single task do the select(), and setting an appropriate semaphore
> on return. The rest of the tasks which would normally do a select()
> instead wait on this semaphore -- when the semaphore is available,
> a single task is unblocked from waiting on it.

Besides being an ugly guru trick, this solution involves the extra
overhead of a semaphore and a process to manage it.

I'm fairly sure this wouldn't take even a kB of kernel memory,
and it would really be nice for userspace hackers to have.

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

\
 
 \ /
  Last update: 2005-03-22 13:50    [W:0.034 / U:0.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site