in reply to CPU Monitor

Have a look at Time::HiRes.

Its Examples section includes an example for timing portions of code.

E.g.:

# measure elapsed time # (could also do by subtracting 2 gettimeofday return values) $t0 = [gettimeofday]; # do bunch of stuff here $t1 = [gettimeofday]; # do more stuff here $t0_t1 = tv_interval $t0, $t1;
Searched for donut and crumpit. Found donate and stumbit instead.