Re: droped out precise time calculations in src/interfaces/libpq/fe-connect.c - Mailing list pgsql-hackers

From Joe Conway
Subject Re: droped out precise time calculations in src/interfaces/libpq/fe-connect.c
Date
Msg-id 3DAD0062.2040400@joeconway.com
Whole thread Raw
In response to Re: droped out precise time calculations in src/interfaces/libpq/fe-connect.c  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-hackers
Bruce Momjian wrote:
> Well, the fact you see a change of 0.0002 is significant.  Let me add
> that in the old code there was only one time() call _in_ the loop, while
> now, there are two, so I can easily see there are several additional
> time() calls.  Did you put your calls in the while loop?
> 

Not the first time, but I moved it around (into the loop in connectDBComplete, 
and just before select() in pqWaitTimed) and it didn't seem to make any 
difference. Then I removed it entirely again, and still got 0.0089 seconds 
average. So, at the least, 0.0002 worth of variation seems to be related to 
the development machine itself.

Joe

p.s. The good news is that with tens of thousands more tests at 1 second 
timeout, still zero connection failures!




pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Postgresql and multithreading
Next
From: Anuradha Ratnaweera
Date:
Subject: Re: Postgresql and multithreading