X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-6.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,TW_FD,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Message-ID: <4D8A0C8F.7040504@redhat.com> Date: Wed, 23 Mar 2011 09:06:55 -0600 From: Eric Blake User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.15) Gecko/20110307 Fedora/3.1.9-0.39.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.9 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: python select() is limited to fds < 64 References: <4D88F89B DOT 6000308 AT dronecode DOT org DOT uk> <4D88FE3E DOT 2070607 AT sh DOT cvut DOT cz> <20110322200804 DOT GA22409 AT ednor DOT casa DOT cgf DOT cx> <4D89DA22 DOT 9010404 AT dronecode DOT org DOT uk> <20110323150038 DOT GE13862 AT ednor DOT casa DOT cgf DOT cx> In-Reply-To: <20110323150038.GE13862@ednor.casa.cgf.cx> OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enigF1DBA4039F75119C316385ED" X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com --------------enigF1DBA4039F75119C316385ED Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 03/23/2011 09:00 AM, Christopher Faylor wrote: > On Wed, Mar 23, 2011 at 11:31:46AM +0000, Jon TURNEY wrote: >> On 22/03/2011 20:08, Christopher Faylor wrote: >>> On Tue, Mar 22, 2011 at 08:53:34PM +0100, V??clav Haisman wrote: >>>> Jon TURNEY wrote, On 22.3.2011 20:29: >>>>> >>>>> python seems to be built with the default value of FD_SETSIZE, which = is >>>>> only 64 on cygwin. >>>> Is this not because of the inherent limitation of >>>> WaitForMultipleObjects() call? >>> >>> Yep. Without a rewrite, it's a hard limit to Cygwin's select(). >> >> Please read my email more closely. I am not saying "python select() is >> limited to waiting on 64 fds or less", I am saying "python select() is >> limited to waiting on fd which are less than 64" >=20 > I forgot to add one bit of data. Unless you go out of your way to > change it, Cygwin's select can't wait for an fd > 63. It's basically a > bit mask. So, there are two limitations: 1) the number of handles that > you can wait for with WaitForMultipleObjects() and 2) the size of > Cygwin's fd_set. Which is why poll() was invented - it lets you wait on fds > 63 (however, you are still limited by WaitForMultipleObjects that nfds of poll() must be <=3D 63). --=20 Eric Blake eblake AT redhat DOT com +1-801-349-2682 Libvirt virtualization library http://libvirt.org --------------enigF1DBA4039F75119C316385ED Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJNigyPAAoJEKeha0olJ0NqH+wH/RJbFywbRi6KV0Un1eiuc+6i 0Ex4M02Md39cwWoydi3nipW066DFyPk0V9JWiBrQRIlUgYUFDFTUfhXxiRh1uQh2 aYfkhhKer3xD3U/534F5xRgdwlwPXPIwzzpdy5bM3f38SRCR0OwDR6DRyU4FP5tH C1RGBdA2D02nccfH89m98/TWHVtpSbJPFW/b3qkpm5WxCQCyITLByWM41/fEER7M iK1+3XEeWWn0axGNhXjMkkSgYf7pMJShB1R+K3GDp16FeJ2+/vTyK2Cfzje2McCF 0cvfKQaW9CIHXP/UnVPvaU/AOFuzINfncBXefQUsUukUZLdV8kL//LUFUWi/QxQ= =kBlV -----END PGP SIGNATURE----- --------------enigF1DBA4039F75119C316385ED--