JavaScript Editor Javascript validator     Web page editor 



Benchmark_Profiler

Benchmark_Profiler -- About Benchmark_Profiler

About Benchmark_Profiler

This class behaves mostly like Benchmark_Timer with the exception that you are allowed to specify the beginning and end of sections within the code to be profiled. sections are different from markers (markers) don't have ends in the sense that they are stateful and remember how many times they have been entered.

Timing information is recorded at the beginning and end of the code to be profiled and at the beginning and end of every section everytime it is encountered. An example follows.

The example above will generate an output as shown below when run with the PHP CLI SAPI. Running it with the Apache SAPI will produce the same results, but formatted as HTML.

As you can see, the default output may not be too helpful. You can obtain detailed section by section profiling information in manual mode through methods like getSectionInformations() and getAllSectionsInformations(). Refer to the API documentation for more information.




JavaScript Editor Javascript validator     Web page editor