On Sat, Mar 12, 2005 at 03:29:32PM -0800, Michael G Schwern wrote: > > Well, if you're just going to look at the wall clock, why use the shell?
Err...because I forgot about the simple 'time' command? > my $start_time = time; > `$bin diff 1/1 2>&1`; > my $end_time = time; > my $time = $end_time - $start_time; > > If you throw Time::HiRes in there you can get fractional second granularity. > > There is also a benchmarking module cunningly named "Benchmark" which you > should have a look at. Now now, I mentioned in the message I looked at 'Benchmark' first and it didn't work. I got the sense it might have only been timing the Perl parts of the code, which makes sense if you are using it to optimize Perl rather than system calls. For what I need, I think simply calling 'time' will do. Thanks. Mark -- http://mark.stosberg.com/