R8B-0 devpoll patch
Tue Mar 5 10:57:35 CET 2002
Sorry for the long delay. I had to catch a few deadlines.
Per Bergqvist <per@REDACTED> writes:
> > Yes, you can select(2)/poll(2) on kqueue descriptors. You can also
> > register kqueue descriptors on another kqueue just to add to the
> > orthogonality.
> A few other questions:
> 1) What is the best way to check if the fd should use poll or kqueue ?
> (in the Linux I do a fstat and test the mode)
Try to register a kevent and see if it fails? I haven't really thought about
> 2) Do you have to register EVFILT_READ and WRITE as separate event
> filters or can you simply OR them in one event ?
separate events. Anything else wouldn't allow the kqueue to live up to what
it promises (all events will be delivered if registering succeeds, resources
allocated on registration and not delivery).
More information about the erlang-questions