XP is just a number | |
PerlMonks |
Re^5: Optimize my code with Hashesby jethro (Monsignor) |
on Aug 27, 2008 at 14:30 UTC ( [id://707173]=note: print w/replies, xml ) | Need Help?? |
Sorry if my answer sounded too harsh, I'm not a native english speaker myself The part of the code you show seems to be quite efficient and from what I can see the author of this code knows how to program in perl. I even tried out the program (the bit you posted) on my machine and it needed just over 1 second (3 seconds on a sun blade 100) to init the hash with 50000 bogus entries and run the loop over it. Naturally with empty subroutines, so no surprise really. What you don't show is what createEDentry and updateEDentry do. Probably that is where most of the work is done. If you want to try yourself, here is my test code. Run it on your machine, if it takes less than 20 seconds, the problem is not in the code you have shown us.
In Section
Seekers of Perl Wisdom
|
|