[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [Libevent-users] FD_SETSIZE - max connections in Windows - help!



On Tue, Mar 16, 2010 at 6:50 AM, W.C.A. Wijngaards <wouter@xxxxxxxxxxxx> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> This problem is 64 max for the windows event notification calls,
> WSAWaitForMultipleEvents.  select() probably calls one of the others
> behind the scenes.
>
> Best regards,
>   Wouter
>

I don't think that's true, Wouter: sure, the WaitForMultiple functions
have a 64-handle limit, but select() honestly doesn't.  At least, it
doesn't on the versions of Windows I've tested.  I just tried out 96
fds with select on Windows select in Libevent 2's "main/many_events"
test, and it worked just fine on my Windows XP environment.  (I just
bumped the definition of MANY in that test to 70 so that   it will be
easier for the unit tests to catch any Windows installations that do
break select in this way.)

A quick trip to codesearch.google.com shows that we're not the only
ones to use more than 64 fds with Windows select:  check out w32poll.c
in nspr, or  WindowsSelectorImpl.c from JDK7.

I don't know what's going on with Patrick's situation, but I pretty
sure that it's more complicated than Windows select() having a
universal 64-socket hard limit.

yrs,
-- 
Nick
***********************************************************************
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users    in the body.