[erlang-questions] Increase the handle limit

Rickard Green rickard.s.green@REDACTED
Tue Oct 25 14:27:24 CEST 2011


Joel Reymont wrote:
> Apparently, the main complaint has been about the lack of kqueue support for TTYs, which was resolved in Lion.
>
> On Oct 24, 2011, at 1:31 PM, Rickard Green wrote:
>
>> There may of course always be improvements in future releases. We fall back on select() on MacOSX since our configure test for a poll() implementation that can handle devices fails. When poll() on MacOSX can handle devices, it will automatically be used as fallback instead of select().

Joel Reymont wrote:
> On Oct 24, 2011, at 1:31 PM, Rickard Green wrote:
>
>> > $ man kqueue
>> > ...
>> > BUGS
>> >     Not all filesystem types support kqueue-style notifications.  And even some that do, like some remote filesystems, may only support a subset of the notification semantics described here.
> As far as I've been told on the darwin-dev list, that refers to vnode-watching which select() doesn't support anyway.
>
>> > $ man poll
>> > ...
>> > BUGS
>> >     The poll() system call currently does not support devices.
>
> This is, likely, a legacy consideration as kqueue was not complete in earlier versions of Mac OSX.
>
> select and poll are subsets of kqueue functionality-wise.

I tried to access the darwin-dev web archive, but I'm not able to access 
it, so I don't know what have been said to you there.

If/when kqueue() can handle all types of file-descriptors that select() 
can handle with *no* exceptions, no fallback is needed. We need to know 
that this is the case for *certain* before a no-fallback solution can be 
used. This is needed for backward compatibility.

If/when poll() can handle all types of file-descriptors that select() 
can handle with *no* exceptions, poll() can be used as fallback instead 
of select().

I did a quick test on our MacOSX Lion machine which suggests that 
kqueue() cannot be used for devices. I may have made something wrong, 
though, but I don't have more time to put on this. I'm quite sure we 
need select() as fallback, but I could be wrong.

If you think kqueue() on MacOSX can be used without fallback, you have 
to dig that information up and present it for us. Also provide us with 
test cases that show that it for example can handle devices, etc...

Regards,
Rickard
-- 
Rickard Green, Erlang/OTP, Ericsson AB.



More information about the erlang-questions mailing list