[Bug 2030784] Re: Backport Intel's AVX512 patches on openssl 3.0
Bun K Tan
2030784 at bugs.launchpad.net
Mon Mar 11 03:35:05 UTC 2024
Hello @adrien-n,
I had Dan Zimmerman take a look at this issue and found a solution.
This is what he shared:
Steps to reproduce:
-------------------
Get Source and apply patch:
git clone https://git.launchpad.net/ubuntu/+source/openssl ubuntu_openssl
cd ubuntu_openssl
git checkout applied/ubuntu/devel
git apply 001-vaes_gcm_avx512.patch (See comment #11 for attachment)
This patch is essentially what is referred to as "[PATCH 2/2] AES-GCM enabled with AVX512 vAES and vPCLMULQDQ."
Build OpenSSL
./config --prefix=/tmp/ubuntu_openssl_install --openssldir=/tmp/ubuntu_openssl_install
make -j
make test
Note AES-GCM Test Failures
Steps to resolution:
--------------------
Apply patch:
make clean
git apply 002-vaes_gcm_avx512_fix.patch
make -j
make test
Note AES-GCM Tests Pass
Solution:
---------
The solution to the failed test cases comes from this merged OpenSSL Pull Request: Avoid having another copy of key schedule in PROV_GCM_CTX by t8m · Pull Request #22384 · openssl/openssl (github.com)
Direct application of this PR will fail due to the fact that the OpenSSL doesn't support SM4_GCM in v3.0.13. So I made the edits by hand and created the patch file 002-vaes_gcm_avx512_fix.patch
** Patch added: "002-vaes_gcm_avx512_fix.patch"
https://bugs.launchpad.net/ubuntu/+source/openssl/+bug/2030784/+attachment/5754725/+files/002-vaes_gcm_avx512_fix.patch
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to openssl in Ubuntu.
https://bugs.launchpad.net/bugs/2030784
Title:
Backport Intel's AVX512 patches on openssl 3.0
Status in openssl package in Ubuntu:
Fix Released
Bug description:
https://github.com/openssl/openssl/pull/14908
https://github.com/openssl/openssl/pull/17239
These should provide a nice performance bonus on recent CPUs, and the
patches are fairly self-contained.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openssl/+bug/2030784/+subscriptions
More information about the foundations-bugs
mailing list