Robert Killheffer wrote:> I'm testing several different algorithms for performing the same task, and> I'm wondering if there is some way I can tell
- from within each version of> my script - how much memory and CPU time the script uses each time it runs.> > > > I would like to be able
to output
I'm testing several different algorithms for performing the same task, and
I'm wondering if there is some way I can tell - from within each version of
my script - how much memory and CPU time the script uses each time it runs.
I would like to be able to output this information to a log, so that I
ob> > -Original Message-> From: Daniel Rawson [mailto:[EMAIL PROTECTED] > Sent:
Tuesday, March 14, 2006 9:08 AM> To: Robert Killheffer> Cc: perl-win32-users@listserv.activestate.com> Subject: Re: System resources used by Perl script>
> Robert Killheffer wrote:>
I think you can try the Benchmark module. Like:
use Benchmark qw(:all) ;
$line = ABCDEFGHIJKLMNOPQRSTUVWXYZ'; $r = timethese(100, { 'CASE 1' => sub { $line =~ /\w*\w*\w*/;
dprofpp, times(2)
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On
> Behalf Of Chris
> Sent: Tuesday, March 14, 2006 11:58 PM
> To: 'Robert Killheffer'; perl-win32-users@listserv.ActiveState.com
> Subject: RE: System resources used b