[gnutls-devel] GnuTLS | lib: add support for Hygon Genuine CPUs in x86 acceleration (!2053)
Read-only notification of GnuTLS library development activities
gnutls-devel at lists.gnutls.org
Wed Jan 14 06:22:48 CET 2026
xinpeng wang created a merge request: https://gitlab.com/gnutls/gnutls/-/merge_requests/2053
Project:Branches: wxphaha/gnutls:adapter-Hygon to gnutls/gnutls:master
Author: xinpeng wang
<!-- Add a description of the new feature/bug fix. Reference any relevant bugs. -->
* lib: add support for Hygon Genuine CPUs in x86 acceleration
Hygon CPUs (HygonGenuine) share the same AES-NI and other crypto
instruction sets with AMD Zen architecture. However, they were previously
falling back to the generic software provider because the vendor check
only recognized Intel and AMD.
This fallback to the software provider (Nettle wrapper) could lead to
numerical issues or crashes (e.g., divide-by-zero) in certain
environments like Photoshop.
This patch:
1. Adds X86_CPU_VENDOR_HYGON to x86_cpu_vendor enum.
2. Updates check_x86_cpu_vendor() to recognize Hygon CPUs.
3. Enables hardware acceleration for Hygon CPUs.
Signed-off-by: xinpeng.wang <wangxinpeng at uniontech.com>
## Checklist
* [ ] Commits have `Signed-off-by:` with name/author being identical to the commit author
* [ ] Code modified for feature
* [ ] Test suite updated with functionality tests
* [ ] Test suite updated with negative tests
* [ ] Documentation updated / NEWS entry present (for non-trivial changes)
## Reviewer's checklist:
* [ ] Any issues marked for closing are addressed
* [ ] There is a test suite reasonably covering new functionality or modifications
* [ ] Function naming, parameters, return values, types, etc., are consistent and according to `CONTRIBUTION.md`
* [ ] This feature/change has adequate documentation added
* [ ] No obvious mistakes in the code
--
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/2053
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20260114/01d6ce67/attachment-0001.html>
More information about the Gnutls-devel
mailing list