ProfilerProfiler mk Tue, 03/30/2010 - 16:32
8.18 Performance profiler
A key issue in developing fast programs using the Monet database back-end requires a keen eye on where performance is lost. Although performance tracking and measurements are highly application dependent, a simple to use tool makes life a lot easier (See stethoscope and tomograph).
Activation of the performance monitor has a global effect, i.e. all concurrent actions on the kernel are traced, but the events are only sent to the client who initiated the profiler thread.
The profiler event can be handled in several ways. The default strategy is to ship the event record immediately over a stream to a performance monitor. An alternative strategy is preparation of off-line performance analysis, where event information is retained in tables.
To reduce the interference of performance measurement with the experiments, the user can use an event cache, which is emptied explicitly upon need.
- module profiler;
- address CMDopenProfilerStream comment "Send the events to output stream";
- address CMDcloseProfilerStream comment "Stop sending the event records";
- address CMDsetFilterVariable comment "Generate an event record for every instruction where v is used."
- address CMDstartProfiler comment "Start performance tracing";
- address CMDstopProfiler comment "Stop performance tracing";
- address CMDclearTrace comment "Clear the profiler traces";
- address CMDgetTrace comment "Get the trace details of a specific event";
- address CMDcleanup comment "Remove the temporary tables for profiling";
- address CMDgetDiskReads comment "Obtain the number of physical reads";
- address CMDgetDiskWrites comment "Obtain the number of physical reads";
- address CMDgetUserTime comment "Obtain the user timing information.";
- address CMDgetSystemTime comment "Obtain the user timing information.";