develooper Front page | perl.perl5.porters | Postings from August 2001

Re: [PATCH] Callbacks to core, with benchmarks

Thread Previous
From:
David M. Lloyd
Date:
August 22, 2001 07:39
Subject:
Re: [PATCH] Callbacks to core, with benchmarks
Message ID:
Pine.LNX.4.33.0108220936230.1027-100000@homebody.freemm.org
On Wed, 22 Aug 2001, David M. Lloyd wrote:

> I have benchmarked the effects of callbacks on performance, by timing
> execution of this expression:
>
> for $x (1..10000000) {}
>
> with and without a callback enabled.
<...>
> I fully expected the first two to be nearly identical... not sure why they
> aren't; the configs are the same.

Never mind; on a hunch I upped the loop to for $x (1..100000000) {} and
now I get nearly identical times:

Without patch:
real 39.0950
user 39.0900
sys   0.0000

versus

With patch:
real 39.0955
user 39.0800
sys   0.0100

Whew.

- D

<dmlloyd@tds.net>


Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About