I don't think it has to do with the 64-bit version of the Mersenne Twister algorithm that the module uses, as it runs through essentially the same code as the 32-bit version (just using different constants). In fact, the 64-bit version has to refresh the random number buffer twice as often, so it's actually doing more work!
One source of improvement may be better utilization of the CPU (Pentium 4) with everything getting done in 64-bit mode to match the CPU registers.
Another may be that since my Perl is compiled with 'use64bitint', it may be using the 64-bit ints from the PRNG directly, and not having to convert them from 32-bits (output of the old PRNG) to 64-bits (Perl's internal representation). (Not sure about this.)
Regardless, it was totally unexpected. Anyone else had any experience with this sort of thing?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: 64-bit Zoom!
by cbrandtbuffalo (Deacon) on Jul 07, 2005 at 20:41 UTC | |
by jdhedden (Deacon) on Jul 08, 2005 at 13:36 UTC | |
|
Re: 64-bit Zoom!
by hossman (Prior) on Jul 07, 2005 at 21:16 UTC | |
|
Re: 64-bit Zoom!
by monarch (Priest) on Jul 08, 2005 at 08:10 UTC |