|
PostgreSQL Source Code git master
|
#include "portability/instr_time.h"

Go to the source code of this file.
Data Structures | |
| struct | BufferUsage |
| struct | WalUsage |
| struct | Instrumentation |
| struct | NodeInstrumentation |
| struct | WorkerNodeInstrumentation |
| struct | TriggerInstrumentation |
Typedefs | |
| typedef struct BufferUsage | BufferUsage |
| typedef struct WalUsage | WalUsage |
| typedef enum InstrumentOption | InstrumentOption |
| typedef struct Instrumentation | Instrumentation |
| typedef struct NodeInstrumentation | NodeInstrumentation |
| typedef struct WorkerNodeInstrumentation | WorkerNodeInstrumentation |
| typedef struct TriggerInstrumentation | TriggerInstrumentation |
Enumerations | |
| enum | InstrumentOption { INSTRUMENT_TIMER = 1 << 0 , INSTRUMENT_BUFFERS = 1 << 1 , INSTRUMENT_ROWS = 1 << 2 , INSTRUMENT_WAL = 1 << 3 , INSTRUMENT_IO = 1 << 4 , INSTRUMENT_ALL = PG_INT32_MAX } |
Variables | |
| PGDLLIMPORT BufferUsage | pgBufferUsage |
| PGDLLIMPORT WalUsage | pgWalUsage |
| typedef struct BufferUsage BufferUsage |
| Enumerator | |
|---|---|
| INSTRUMENT_TIMER | |
| INSTRUMENT_BUFFERS | |
| INSTRUMENT_ROWS | |
| INSTRUMENT_WAL | |
| INSTRUMENT_IO | |
| INSTRUMENT_ALL | |
Definition at line 61 of file instrument.h.
|
externinline |
Definition at line 327 of file instrument.c.
References fb(), INSTR_TIME_ACCUM_DIFF, BufferUsage::local_blk_read_time, BufferUsage::local_blk_write_time, BufferUsage::local_blks_dirtied, BufferUsage::local_blks_hit, BufferUsage::local_blks_read, BufferUsage::local_blks_written, BufferUsage::shared_blk_read_time, BufferUsage::shared_blk_write_time, BufferUsage::shared_blks_dirtied, BufferUsage::shared_blks_hit, BufferUsage::shared_blks_read, BufferUsage::shared_blks_written, BufferUsage::temp_blk_read_time, BufferUsage::temp_blk_write_time, BufferUsage::temp_blks_read, and BufferUsage::temp_blks_written.
Referenced by do_analyze_rel(), ExplainExecuteQuery(), heap_vacuum_rel(), InstrEndParallelQuery(), InstrStopCommon(), pgss_planner(), pgss_ProcessUtility(), serializeAnalyzeReceive(), and standard_ExplainOneQuery().
|
extern |
Definition at line 297 of file instrument.c.
References BufferUsageAdd(), pgBufferUsage, pgWalUsage, and WalUsageAdd().
Referenced by _brin_end_parallel(), _bt_end_parallel(), _gin_end_parallel(), ExecParallelFinish(), and parallel_vacuum_process_all_indexes().
|
extern |
Definition at line 232 of file instrument.c.
References Assert, BufferUsageAdd(), fb(), INSTR_TIME_ADD, and WalUsageAdd().
Referenced by ExecParallelReportInstrumentation(), and ExecParallelRetrieveInstrumentation().
|
extern |
Definition at line 36 of file instrument.c.
References InstrInitOptions(), and palloc0_object.
Referenced by standard_ExecutorStart().
|
extern |
Definition at line 112 of file instrument.c.
References InstrInitNode(), and palloc_object.
Referenced by ExecInitNode().
|
extern |
Definition at line 253 of file instrument.c.
References fb(), i, InstrInitOptions(), and palloc0_array.
Referenced by InitResultRelInfo().
|
extern |
Definition at line 204 of file instrument.c.
References NodeInstrumentation::counter, elog, ERROR, NodeInstrumentation::firsttuple, NodeInstrumentation::instr, INSTR_TIME_ADD, INSTR_TIME_IS_ZERO, INSTR_TIME_SET_ZERO, NodeInstrumentation::nloops, NodeInstrumentation::ntuples, NodeInstrumentation::running, Instrumentation::starttime, NodeInstrumentation::startup, Instrumentation::total, and NodeInstrumentation::tuplecount.
Referenced by ExecParallelReportInstrumentation(), ExecReScan(), ExplainNode(), and show_modifytable_info().
|
extern |
Definition at line 287 of file instrument.c.
References BufferUsageAccumDiff(), fb(), pgBufferUsage, pgWalUsage, save_pgBufferUsage, save_pgWalUsage, and WalUsageAccumDiff().
Referenced by _brin_parallel_build_main(), _bt_parallel_build_main(), _gin_parallel_build_main(), parallel_vacuum_main(), and ParallelQueryMain().
|
extern |
Definition at line 123 of file instrument.c.
References NodeInstrumentation::async_mode, fb(), NodeInstrumentation::instr, and InstrInitOptions().
Referenced by ExecInitParallelPlan(), and InstrAllocNode().
|
extern |
Definition at line 45 of file instrument.c.
References INSTRUMENT_BUFFERS, INSTRUMENT_TIMER, INSTRUMENT_WAL, Instrumentation::need_bufusage, Instrumentation::need_timer, and Instrumentation::need_walusage.
Referenced by InstrAlloc(), InstrAllocTrigger(), and InstrInitNode().
|
externinline |
Definition at line 53 of file instrument.c.
References Instrumentation::bufusage_start, elog, ERROR, INSTR_TIME_IS_ZERO, INSTR_TIME_SET_CURRENT_FAST, Instrumentation::need_bufusage, Instrumentation::need_timer, Instrumentation::need_walusage, pgBufferUsage, pgWalUsage, Instrumentation::starttime, and Instrumentation::walusage_start.
Referenced by InstrStartNode(), InstrStartTrigger(), standard_ExecutorFinish(), and standard_ExecutorRun().
|
externinline |
Definition at line 132 of file instrument.c.
References NodeInstrumentation::instr, and InstrStart().
Referenced by ExecAsyncConfigureWait(), ExecAsyncNotify(), ExecAsyncRequest(), ExecProcNodeInstr(), ExecShutdownNode_walker(), MultiExecBitmapAnd(), MultiExecBitmapIndexScan(), MultiExecBitmapOr(), and MultiExecHash().
Definition at line 279 of file instrument.c.
References pgBufferUsage, pgWalUsage, save_pgBufferUsage, and save_pgWalUsage.
Referenced by _brin_parallel_build_main(), _bt_parallel_build_main(), _gin_parallel_build_main(), parallel_vacuum_main(), and ParallelQueryMain().
|
extern |
Definition at line 265 of file instrument.c.
References fb(), and InstrStart().
Referenced by AfterTriggerExecute(), and ExecCallTriggerFunc().
|
extern |
Definition at line 103 of file instrument.c.
References InstrStopCommon(), and Instrumentation::total.
Referenced by InstrStopTrigger(), standard_ExecutorFinish(), and standard_ExecutorRun().
|
externinline |
Definition at line 139 of file instrument.c.
References NodeInstrumentation::async_mode, NodeInstrumentation::counter, fb(), NodeInstrumentation::firsttuple, NodeInstrumentation::instr, InstrStopCommon(), NodeInstrumentation::running, and NodeInstrumentation::tuplecount.
Referenced by ExecAsyncConfigureWait(), ExecAsyncNotify(), ExecAsyncRequest(), ExecProcNodeInstr(), ExecShutdownNode_walker(), MultiExecBitmapAnd(), MultiExecBitmapIndexScan(), MultiExecBitmapOr(), and MultiExecHash().
|
extern |
Definition at line 271 of file instrument.c.
References fb(), and InstrStop().
Referenced by AfterTriggerExecute(), and ExecCallTriggerFunc().
|
extern |
Definition at line 196 of file instrument.c.
References NodeInstrumentation::tuplecount.
Referenced by complete_pending_request(), and ExecMergeMatched().
Definition at line 367 of file instrument.c.
References fb(), WalUsage::wal_buffers_full, WalUsage::wal_bytes, WalUsage::wal_fpi, WalUsage::wal_fpi_bytes, and WalUsage::wal_records.
Referenced by do_analyze_rel(), heap_vacuum_rel(), InstrEndParallelQuery(), InstrStopCommon(), pgss_planner(), pgss_ProcessUtility(), pgstat_flush_backend_entry_wal(), and pgstat_wal_flush_cb().
|
extern |
Definition at line 25 of file instrument.c.
Referenced by AsyncReadBuffers(), BufFileDumpBuffer(), BufFileLoadBuffer(), do_analyze_rel(), ExplainExecuteQuery(), ExtendBufferedRelLocal(), ExtendBufferedRelShared(), FlushBuffer(), FlushLocalBuffer(), heap_vacuum_rel(), InstrAccumParallelQuery(), InstrEndParallelQuery(), InstrStart(), InstrStartParallelQuery(), InstrStopCommon(), MarkBufferDirty(), MarkLocalBufferDirty(), MarkSharedBufferDirtyHint(), pgss_planner(), pgss_ProcessUtility(), pgstat_count_io_op_time(), ReadRecentBuffer(), serializeAnalyzeReceive(), standard_ExplainOneQuery(), and TrackBufferHit().
|
extern |
Definition at line 27 of file instrument.c.
Referenced by AdvanceXLInsertBuffer(), do_analyze_rel(), heap_page_prune_and_freeze(), heap_vacuum_rel(), InstrAccumParallelQuery(), InstrEndParallelQuery(), InstrStart(), InstrStartParallelQuery(), InstrStopCommon(), pgss_planner(), pgss_ProcessUtility(), pgstat_backend_wal_have_pending(), pgstat_create_backend(), pgstat_flush_backend_entry_wal(), pgstat_wal_flush_cb(), pgstat_wal_have_pending(), pgstat_wal_init_backend_cb(), and XLogInsertRecord().