On 10/31/07, Mike Klaas <[EMAIL PROTECTED]> wrote: > Issue http://bugs.python.org/issue1663329 details an annoyance in the > subprocess module that has affected several users, including me. > Essentially, closing hundreds of thousands of file descriptors by > round-tripping through the python exception machinery is very slow, > taking hundreds of milliseconds and at times many seconds. The > proposed fix is to write this loop in c. The c function is but a > handful of lines long. I purposefully kept the implementation > trivial so that it will work on all unix variants (there is another > issue that contains a super-duper optimization for AIX, and other > possibilities exist for Solaris, but the simple fix yields a ten-fold > speedup everywhere but windows, so I didn't think that it was worth > the complexity). > > Though technically relating only to performance, I consider this a > bug-fix candidate as mysterious multi-second delays when launching a > subprocess end up making the functionality of close_fds unusable on > some platform configurations (namely, those with high MAX_FD set). > > It would be great to see this is 2.5.2. Understanding that issue > evaluation takes significant effort, I've done some evaluation/triage > on other open tickets:
Thanks for doing these! Since people are already jumping on those bugs but nobody has voiced an opinion on your own patch, let me say that I think it's a good patch, and I want it in 2.6, but I'm reluctant to add it to 2.5.2 as it goes well beyond a bugfix (adding a new C API and all that). -- --Guido van Rossum (home page: http://www.python.org/~guido/) _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com