In addition to all the other good advice, you might want to take a peek at Benchmark::Timer. It's a constituant part of the Benchmark module.
It has the nice ability to allow you to start and stop as many timers as you want in whatever order, and more than once. It accumlates the times for each named timer and provides a nicely formatted 'potted' report on demand.
In reply to Re: Perl code timing
by BrowserUk
in thread Perl code timing
by mcogan1966
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |