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 Date: Thu, 19 Jun 2003 22:17:54 -0400 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: stderr outputs veerrrryyy slowly Message-ID: <20030620021754.GA19653@redhat.com> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <3EF099C8 DOT 8FDEC855 AT dessent DOT net> <3EF09ED6 DOT F4943C46 AT dessent DOT net> <3EF0B792 DOT 40204 AT cygwin DOT com> <3EF0BFA2 DOT 99CCC92A AT dessent DOT net> <3EF26B27 DOT 1020203 AT cygwin DOT com> <20030620021155 DOT GA19483 AT redhat DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030620021155.GA19483@redhat.com> User-Agent: Mutt/1.4.1i On Thu, Jun 19, 2003 at 10:11:55PM -0400, Christopher Faylor wrote: >On Thu, Jun 19, 2003 at 10:02:15PM -0400, Larry Hall wrote: >>Brian Dessent wrote: >>>Larry Hall wrote: >>>>Works for me fine either way. Perhaps providing information >>>>requested by will shed some light. >>>>Perhaps not. >>>> >>>>You could try it with strace and post the results too. >>> >>>Ok, attached should be the cygcheck -srv output. Also, the strace log >>>for running "tidy" on a html file is at >>> It's pretty big, about 17000 >>>lines. Of interest are two things: >>> >>>Running it under strace fixes the problem (!!) more or less. The output >>>is much faster, although not quite as fast as you would expect for >>>console output: >>> >>>time strace -o strace.out tidy -o foo test.html >>>... >>>real 0m4.640s >>>user 0m0.010s >>>sys 0m0.020s >>> >>>time tidy -o foo test.html >>>... >>>real 0m39.301s >>>user 0m0.070s >>>sys 0m0.020s >> >>OK, I have been able to reproduce this to some extent. I'm using 'curl >>-o /dev/null http://www.google.com' which times in at about 1.5 to 2 >>seconds with 'tty' and about .5 seconds without. I don't have any >>additional data at this point but I thought I'd "chime in" with a "me >>too", since I know that's what this list is all about. ;-) Actually, I >>wanted to let Brian and any others know that this doesn't appear to be >>specific to their configuration. If I find out more, I'll report back. > >This crops up on the cygwin list from time to time. > >IIRC, if you use 'setbuf(f, NULL)' in newlib (as is the case for from >stderr), it causes newlib to flush on every character. I submitted a >patch to fix this behavior many years ago but it was rejected. I think >the rationale was basically a "This isn't broken. We're allowed to do >this" but I don't really recall exactly why the patch was rejected. -- 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/