31InstrAlloc(
int n,
int instrument_options,
bool async_mode)
44 for (
i = 0;
i < n;
i++)
72 elog(
ERROR,
"InstrStartNode called twice in a row");
96 elog(
ERROR,
"InstrStopNode called without start");
147 elog(
ERROR,
"InstrEndLoop called on running node");
167 if (!
dst->running &&
add->running)
170 dst->firsttuple =
add->firsttuple;
172 else if (
dst->running &&
add->running &&
174 dst->firsttuple =
add->firsttuple;
178 dst->tuplecount +=
add->tuplecount;
181 dst->ntuples +=
add->ntuples;
182 dst->ntuples2 +=
add->ntuples2;
183 dst->nloops +=
add->nloops;
184 dst->nfiltered1 +=
add->nfiltered1;
185 dst->nfiltered2 +=
add->nfiltered2;
188 if (
dst->need_bufusage)
191 if (
dst->need_walusage)
225 dst->shared_blks_hit +=
add->shared_blks_hit;
226 dst->shared_blks_read +=
add->shared_blks_read;
227 dst->shared_blks_dirtied +=
add->shared_blks_dirtied;
228 dst->shared_blks_written +=
add->shared_blks_written;
229 dst->local_blks_hit +=
add->local_blks_hit;
230 dst->local_blks_read +=
add->local_blks_read;
231 dst->local_blks_dirtied +=
add->local_blks_dirtied;
232 dst->local_blks_written +=
add->local_blks_written;
233 dst->temp_blks_read +=
add->temp_blks_read;
234 dst->temp_blks_written +=
add->temp_blks_written;
277 dst->wal_bytes +=
add->wal_bytes;
278 dst->wal_records +=
add->wal_records;
279 dst->wal_fpi +=
add->wal_fpi;
280 dst->wal_fpi_bytes +=
add->wal_fpi_bytes;
281 dst->wal_buffers_full +=
add->wal_buffers_full;
#define INSTR_TIME_SET_CURRENT(t)
#define INSTR_TIME_ADD(x, y)
#define INSTR_TIME_IS_ZERO(t)
#define INSTR_TIME_LT(x, y)
#define INSTR_TIME_SET_CURRENT_LAZY(t)
#define INSTR_TIME_SET_ZERO(t)
#define INSTR_TIME_ACCUM_DIFF(x, y, z)
void InstrUpdateTupleCount(Instrumentation *instr, double nTuples)
void InstrAccumParallelQuery(BufferUsage *bufusage, WalUsage *walusage)
void InstrEndLoop(Instrumentation *instr)
Instrumentation * InstrAlloc(int n, int instrument_options, bool async_mode)
static void BufferUsageAdd(BufferUsage *dst, const BufferUsage *add)
void InstrAggNode(Instrumentation *dst, Instrumentation *add)
static BufferUsage save_pgBufferUsage
void InstrEndParallelQuery(BufferUsage *bufusage, WalUsage *walusage)
static WalUsage save_pgWalUsage
static void WalUsageAdd(WalUsage *dst, WalUsage *add)
void WalUsageAccumDiff(WalUsage *dst, const WalUsage *add, const WalUsage *sub)
void InstrStartParallelQuery(void)
BufferUsage pgBufferUsage
void InstrInit(Instrumentation *instr, int instrument_options)
void BufferUsageAccumDiff(BufferUsage *dst, const BufferUsage *add, const BufferUsage *sub)
void InstrStartNode(Instrumentation *instr)
void InstrStopNode(Instrumentation *instr, double nTuples)
void * palloc0(Size size)
instr_time local_blk_read_time
int64 shared_blks_dirtied
instr_time temp_blk_write_time
instr_time shared_blk_read_time
instr_time shared_blk_write_time
instr_time temp_blk_read_time
instr_time local_blk_write_time
int64 shared_blks_written
BufferUsage bufusage_start