If PROFILER doesn insert “probes” into source code, how does it collect its information about program execution?
PROFILER attaches itself to the NATURAL Dispatcher. As each statement is executed, PROFILER will note the CPU time and statement number, then pass the statement on to NATURAL to be executed. When the next statement appears, PROFILER calculates the CPU time for the previous statement and notes the current statement information. Periodically, PROFILER stores the statistical information in an ADABAS file. This method allows PROFILER to monitor EVERY statement execution, not just a few, provides more accurate statistics, and does not require a single change to NATURAL source code.