develooper Front page | perl.perl5.porters | Postings from December 2000

Re: [PATCH] Fcntl constants speedup

Thread Previous
From:
Russ Allbery
Date:
December 17, 2000 14:47
Subject:
Re: [PATCH] Fcntl constants speedup
Message ID:
ylsnnmwtr3.fsf@windlord.stanford.edu
Nicholas Clark <nick@ccl4.org> writes:

> I've not touched pp_modulo (yet)
> Simon's profiles seemed to show it taking a very long time, so it
> appears there's something really bad happening there. Did anyone have
> any idea why it seemed to be so slow?

Is it just the fact that modulo on most platforms is stunningly slow?
It's slow in C as well; that's one of the reasons why most of the folks
recommending hashing algorithms recommend ones that avoid having to take a
modulus if at all possible.  It apparently can swamp a lot of other
constant factors.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

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