Corinna Vinschen <corinna-cygwin <at> cygwin.com> writes: > I created a patch which uses WNetOpenEnum for the existence check, but > it needs extremly long to timeout the existence check in such a case.
There's already a long timeout on unknown names; that's inescapable when dealing with // issues. Without the patch: $ time dash -c 'cd //bin' cd: 1: can't cd to //bin real 0m6.921s user 0m0.046s sys 0m0.015s $ time dash -c 'cd //home' # wrong result real 0m0.187s user 0m0.030s sys 0m0.030s $ time dash -c 'cd //eblake' real 0m0.031s user 0m0.030s sys 0m0.015s With the patch, I see: $ time dash -c 'cd //bin' cd: 1: can't cd to //bin real 0m4.796s user 0m0.030s sys 0m0.030s $ time dash -c 'cd //home' # right result cd: 1: can't cd to //home real 0m0.031s user 0m0.030s sys 0m0.015s $ time dash -c 'cd //eblake' real 0m0.031s user 0m0.030s sys 0m0.015s So, no obvious speed regression on good paths, a whopping 25% performance improvement on paths that previously failed, and the desired failure on the questionable path is now achieved with speed comparable to the success path! I'd say go ahead and apply the patch - the numbers speak for themselves. -- Eric Blake -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple