On Wed, Dec 14, 2011, Marius Peschke wrote:

> Marius Peschke
> 
> Sadly I had to experience that my MD5-speed dropped by roughly 20-25% again 
> without using assembler optimization.(Measurements made by "openssl speed 
> md5")
> 

Looking at how we measure speeds in apps/speed.c the results may not be
realistic: it would depend on how the application uses digest contexts.

In speed.c we call EVP_Digest() on each interation. This will initialise a
EVP_MD_CTX, use it, then clean it. That adds an extra initialisation and clean
up overhead to each operation: which will be more significant for smaller
blocks.

A more efficient way is to instead reuse the same EVP_MD_CTX for all
operations. That way some initialisation and cleanup overheads 
only occur on the initial operation and the final cleanup respectively.

I can't recall if we added some additional operations to initialisation and
cleanup which would account for the difference in 1.0.0x.

Steve.
--
Dr Stephen N. Henson. OpenSSL project core developer.
Commercial tech support now available see: http://www.openssl.org
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to