Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm 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 X-Authentication-Warning: slinky.cs.nyu.edu: pechtcha owned process doing -bs Date: Tue, 21 Oct 2003 15:00:11 -0400 (EDT) From: Igor Pechtchanski Reply-To: cygwin AT cygwin DOT com To: "Linda W." cc: cygwin AT cygwin DOT com Subject: Re: cygwin performance In-Reply-To: <3F957E0D.2060405@tlinx.org> Message-ID: References: <3F957E0D DOT 2060405 AT tlinx DOT org> Importance: Normal MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Tue, 21 Oct 2003, Linda W. wrote: > Has anyone done any testing on performance of cygwin utils over their > native win counterparts? The one that bothers me the most is the > performance of cygwin "Find" and the windows 'find'. If I'm just > looking for filenames (find /c/ -name \*.wav) vs. looking for *.wav in > windows find GUI, the performance difference is very large (maybe > 8-10x?). Is this unavoidable because the way cygwin does emulation or > can optimizations be performed that would benefit all programs (not just > find). I suspect you're not comparing apples to apples here. Later Windows versions run a file indexing service in the background, which makes finding files faster. You might get more relevant results if you tried using "locate" after an "updatedb". > Even using 'perl' over combo's of cat|tr|sed|grep|more is significantly > faster to almost make the old unix standard scripting commands near > worthless (I've gotten more efficient at 1-line perl scripts ala (perl > -e '....'). You can always run these things under strace to see where the time goes. Many factors enter into these slowdowns, e.g., if your Cygwin is installed on a network drive, spawning multiple programs is likely to be much slower than spawning one, no matter how large. > Perhaps it is unavoidable, but I see things like find doing 2 'opens' / > file when it is searching for files...can't it just do a 'stat' of some > nature? does it need to do an open, let alone 2? Which tool do you use see this? FWIW, I see at least one ReadFile in the Cygwin fstat implementation (fstat_helper in fhandler_disk_file.cc), for reading magic numbers to determine the executable bit. > Just wondering.... > tnx, > -linda As always, PTC. Igor -- http://cs.nyu.edu/~pechtcha/ |\ _,,,---,,_ pechtcha AT cs DOT nyu DOT edu ZZZzz /,`.-'`' -. ;-;;,_ igor AT watson DOT ibm DOT com |,4- ) )-,_. ,\ ( `'-' Igor Pechtchanski, Ph.D. '---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow! "I have since come to realize that being between your mentor and his route to the bathroom is a major career booster." -- Patrick Naughton -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/