Date: Fri, 28 Jul 2000 15:05:53 -0500 From: Chris Costello <chris@calldei.com> To: Archie Cobbs <archie@whistle.com> Cc: Doug White <dwhite@resnet.uoregon.edu>, hackers@FreeBSD.ORG Subject: Re: kevent()/kqueue() in a multithreaded environment Message-ID: <20000728150552.N37935@holly.calldei.com> In-Reply-To: <200007281945.MAA26198@bubba.whistle.com> References: <Pine.BSF.4.21.0007271246160.56534-100000@resnet.uoregon.edu> <200007281945.MAA26198@bubba.whistle.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Friday, July 28, 2000, Archie Cobbs wrote: > Doug White writes: > > AFAIK kqueue hasn't been made threadsafe, you'll have to bug > > jlemon@freebsd.org about it. Patches gladly accepted :) > > I may be just being stupid but I don't understand that last sentence. > > I thought kqueue() and kevent() were system calls... how can they > not be thread safe? Consider a kqueue() with a timeout--the calling process does not get woken up until the timeout is completed. Look at src/lib/libc_r/uthread/uthread_poll.c for something similar to how a threaded kevent() could be implemented. I don't think kqueue() would block. -- |Chris Costello <chris@calldei.com> |If a group of N persons implements a COBOL compiler, there will be N-1 |passes. Someone in the group has to be the manager. -- T. Cheatham `---------------------------------------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000728150552.N37935>