diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2006-05-30 19:24:25 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2006-05-30 19:24:25 +0000 |
commit | a18ebc5541c20bf6aca70532bbf1a0531d1b2659 (patch) | |
tree | f77bec1ef5bfe5a97eb998d73954a0e3509294c0 /src/include/executor | |
parent | 3993bd8e07a31dd3b4606a53cc02627da7ed769c (diff) | |
download | postgresql-a18ebc5541c20bf6aca70532bbf1a0531d1b2659.tar.gz postgresql-a18ebc5541c20bf6aca70532bbf1a0531d1b2659.zip |
Code review for EXPLAIN patch. Fix some typos, make it behave sanely
across multiple loops, get rid of the shaky assumption that exactly one
tuple is returned per node iteration.
Diffstat (limited to 'src/include/executor')
-rw-r--r-- | src/include/executor/instrument.h | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/include/executor/instrument.h b/src/include/executor/instrument.h index fbf578d473f..fd57f865788 100644 --- a/src/include/executor/instrument.h +++ b/src/include/executor/instrument.h @@ -6,7 +6,7 @@ * * Copyright (c) 2001-2006, PostgreSQL Global Development Group * - * $PostgreSQL: pgsql/src/include/executor/instrument.h,v 1.14 2006/05/30 14:01:58 momjian Exp $ + * $PostgreSQL: pgsql/src/include/executor/instrument.h,v 1.15 2006/05/30 19:24:25 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -57,20 +57,19 @@ typedef struct Instrumentation { /* Info about current plan cycle: */ bool running; /* TRUE if we've completed first tuple */ + bool sampling; /* Are we sampling in current iteration? */ instr_time starttime; /* Start time of current iteration of node */ instr_time counter; /* Accumulated runtime for this node */ double firsttuple; /* Time for first tuple of this cycle */ double tuplecount; /* Tuples emitted so far this cycle */ - double samplecount; /* Samples collected this cycle */ + double itercount; /* Plan node iterations this cycle */ + double samplecount; /* Iterations in which we sampled runtime */ + double nextsample; /* Next itercount to sample at */ /* Accumulated statistics across all completed cycles: */ double startup; /* Total startup time (in seconds) */ double total; /* Total total time (in seconds) */ double ntuples; /* Total tuples produced */ double nloops; /* # of run cycles for this node */ - double nsamples; /* # of samples taken */ - /* Tracking for sampling */ - bool sampling; /* Are we sampling this iteration */ - double nextsample; /* The next tuplecount we're going to sample */ } Instrumentation; extern Instrumentation *InstrAlloc(int n); |