delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-developers/2002/08/01/18:20:23

Mailing-List: contact cygwin-developers-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-developers-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin-developers/>
List-Post: <mailto:cygwin-developers AT cygwin DOT com>
List-Help: <mailto:cygwin-developers-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-developers-owner AT cygwin DOT com
Delivered-To: mailing list cygwin-developers AT cygwin DOT com
Date: Thu, 1 Aug 2002 18:20:43 -0400
From: Christopher Faylor <cgf AT redhat DOT com>
To: cygwin-developers AT cygwin DOT com
Subject: Re: potential instability in cygwin after my last checkin
Message-ID: <20020801222043.GA30821@redhat.com>
Reply-To: cygwin-developers AT cygwin DOT com
Mail-Followup-To: cygwin-developers AT cygwin DOT com
References: <20020801163716 DOT GA20607 AT redhat DOT com> <010101c239a9$29c04d40$6132bc3e AT BABEL>
Mime-Version: 1.0
In-Reply-To: <010101c239a9$29c04d40$6132bc3e@BABEL>
User-Agent: Mutt/1.3.23.1i

On Thu, Aug 01, 2002 at 11:17:02PM +0100, Conrad Scott wrote:
>"Christopher Faylor" <cgf AT redhat DOT com> wrote:
>> So, it's possible that my current implementation is actually
>slower than
>> the old one.  I'll check on that in the next couple of days.
>
>I've just done some timings with a pair of test programs, where
>the server echoes everything it's sent and the client repeatedly
>sends packets and waits for replies.  They also do a select before
>each read from the socket (I've got a problem with selects for
>writing so that's not in the test program as yet).
>
>Anyhow, timings (done with bash's time command, averages over 3
>runs):
>
>Before Chris's changes:
>
>real    29.9 seconds
>user    1.8 seconds
>system  6.75 seconds
>
>After the changes:
>
>real    23.4
>user    1.3
>system  4.88
>
>which is a nice 20% improvement, not slower at all.
>
>Just for comparison, the same test w/o any selects:
>
>real    1.1
>user    0.15
>system  0.30
>
>so there's still some room for improvement :-)

I think I can whittle that down some.  I'm amazed that the difference
was so great.  I'm even more amazed that there is THAT much overhead
in select().  Wow.

>Of course, the other point here is that the code seems to work
>fine (I'm also running XEmacs w/ gnuserv and CVS too).
>
>// Conrad
>
>p.s. I've been assuming that bash's time command returns sensible
>values for the user and system times: they look plausible.  Are
>they known to be good?

You know, that's a good question.  I have been using /bin/time and
noticing that there may be something funny there because sometimes I get
elapsed times that are less than the total of system and user time.  I
guess that's possible given my dual processor machine but I don't recall
ever seeing that before.

cgf

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019