[openssl/openssl] 04904a: md5: add assembly implementation for aarch64

pauli noreply at reply.github.openssl.org
Tue May 3 04:36:44 UTC 2022


  Branch: refs/heads/master
  Home:   https://github.openssl.org/openssl/openssl
  Commit: 04904a0fff639c058d38b355d75485ca5dde0a89
      https://github.openssl.org/openssl/openssl/commit/04904a0fff639c058d38b355d75485ca5dde0a89
  Author: Jonathan Swinney <jswinney at amazon.com>
  Date:   2022-05-03 (Tue, 03 May 2022)

  Changed paths:
    A crypto/md5/asm/md5-aarch64.pl
    M crypto/md5/build.info
    M crypto/md5/md5_local.h

  Log Message:
  -----------
  md5: add assembly implementation for aarch64

This change improves md5 performance significantly by using a hand-optimized
assembly implementation of the inner loop of md5 calculation. The instructions
are carefully ordered to separate data dependencies as much as possible.

Test with:
$ openssl speed md5

AWS Graviton 2
type             16 bytes    64 bytes     256 bytes    1024 bytes   8192 bytes   16384 bytes
md5              46990.60k   132778.65k   270376.96k   364718.08k   405962.75k   409201.32k
md5-modified     51725.23k   152236.22k   323469.14k   453869.57k   514102.61k   519056.04k
                 +10%        +15%         +20%         +24%         +27%         +27%

Apple M1
type             16 bytes    64 bytes     256 bytes    1024 bytes   8192 bytes   16384 bytes
md5              74634.39k   195561.25k   375434.45k   491004.23k   532361.40k   536636.48k
md5-modified     84637.11k   229017.09k   444609.62k   588069.50k   655114.24k   660850.56k
                 +13%        +17%         +18%         +20%         +23%         +23%

Reviewed-by: Matt Caswell <matt at openssl.org>
Reviewed-by: Paul Dale <pauli at openssl.org>
(Merged from https://github.com/openssl/openssl/pull/16928)




More information about the openssl-commits mailing list