Re: Re: [PEPr] Changes in proposal for Encryption::Crypt_Blowfish
| From: | Matthew Fonda | Date: | Wed, 09 Feb 2005 19:16:21 +0000 |
| Subject: | Re: Re: [PEPr] Changes in proposal for Encryption::Crypt_Blowfish | ||
| References: | 1 2 3 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-36104@lists.php.net to get a copy of this message | ||
Howdy,
You are right, that does make it quite a bit faster. I will use this
method instead. Thank you very much for your contribution
Regards
On Wed, 2005-02-09 at 09:38, Ants Aasma wrote:
> Hi,
>
> I did some quick benchmarking. On a AthlonXP 2500+ the current version
> encrypted 1454kB in 42.37s. Implementing bertrand's patch made it 2.4%
> faster, at 41.36s. By using pack() and unpack() instead of ord() and
> chr() I got 38.24s making it another 8.2% faster. I then inlined the
> _F() method and cleaned it all up a bit. That encrypted the 1.4MB file
> in 20.72s making it more than twice as fast as the original.
>
> You can get the diff against the last version from
> http://www.hot.ee/stepz/Blowfish.php.diff and the view the
> source at
> http://www.hot.ee/stepz/Blowfish.phps.html .
>
> AFAICS everything works, tried encrypting/decrypting a couple of files
> and got the same output.
>
> ---
> Ants