Re: Patch: add timing of buffer I/O requests - Mailing list pgsql-hackers

From Greg Smith
Subject Re: Patch: add timing of buffer I/O requests
Date
Msg-id 4F15B930.50108@2ndQuadrant.com
Whole thread Raw
In response to Re: Patch: add timing of buffer I/O requests  (Greg Smith <greg@2ndQuadrant.com>)
List pgsql-hackers
Attached is the pg_test_timing utility portion of this submission,
broken out into its own patch.  It's a contrib module modeled on
pg_test_fsync.

The documentation is still a bit rough, I'm not done with that yet.  I
have included an example of good timing results, switching to a bad
clock source, and the resulting bad results.  Code review found some
formatting things to nitpick I've already fixed:  non-standard brace
locations and not including enough spaces in expressions were the main two.

This is now referenced by the existing cryptic documentation comment
around EXPLAIN ANALYZE, which says that overhead can be high because
gettimeofday is slow on some systems.  Since this utility measures that
directly, I think it's a clear win to include it just for that purpose.
The fact that there are more places coming where timing overhead matters
is also true.  But this existing one is already bad enough to justify
shipping something to help measure/manage it in my mind.

--
Greg Smith   2ndQuadrant US    greg@2ndQuadrant.com   Baltimore, MD
PostgreSQL Training, Services, and 24x7 Support www.2ndQuadrant.com


Attachment

pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: Group commit, revised
Next
From: Peter Geoghegan
Date:
Subject: Re: Group commit, revised