Mailing List Archive

AVX implementation for PQC
In the course of our project for the integration of PQC into libgcrypt
we also plan to provide an AVX2 implementation. As our implementation is
generally based on the reference implementation, the AVX2 implementation
would also closely follow the one provided in the reference
implementation of the respective scheme, i.e. using immintrin.h. We
plan, however, to create a more unified implementation in that we will
keep common higher level functions with compile-time switches and for
the lower level functions that are completely different for AVX2, we
would create separate files.

Please let me know if that approach sounds suitable for libcrypt and if
you have any comments.

- Falko

--

*MTG AG*
Dr. Falko Strenzke
Executive System Architect

Phone: +49 6151 8000 24
E-Mail: falko.strenzke@mtg.de
Web: mtg.de <https://www.mtg.de>


Follow us
------------------------------------------------------------------------

MTG AG - Dolivostr. 11 - 64293 Darmstadt, Germany
Commercial register: HRB 8901
Register Court: Amtsgericht Darmstadt
Management Board: Jürgen Ruf (CEO), Tamer Kemeröz
Chairman of the Supervisory Board: Dr. Thomas Milde

This email may contain confidential and/or privileged information. If
you are not the correct recipient or have received this email in error,
please inform the sender immediately and delete this email.Unauthorised
copying or distribution of this email is not permitted.

Data protection information: Privacy policy
<https://www.mtg.de/en/privacy-policy>
Re: AVX implementation for PQC [ In reply to ]
Hello,

On 14.11.2023 17.27, Falko Strenzke wrote:
> In the course of our project for the integration of PQC into libgcrypt we also plan to provide an AVX2 implementation. As our implementation is generally based on the reference implementation, the AVX2 implementation would also closely follow the one provided in the reference implementation of the respective scheme, i.e. using immintrin.h. We plan, however, to create a more unified implementation in that we will keep common higher level functions with compile-time switches and for the lower level functions that are completely different for AVX2, we would create separate files.
>

So, if I understood right, higher level functions be compiled both without and with AVX2 using, for example, AVX2_ENABLED macro defined from Makefile. AVX2 implementation would be then selected run-time based on HWF flags and AVX2 would be compiled only if configure.ac detected that compiler supports "immintrin.h" intrinsics.

> Please let me know if that approach sounds suitable for libcrypt and if you have any comments.
>

Sounds good to me.

-Jussi


_______________________________________________
Gcrypt-devel mailing list
Gcrypt-devel@gnupg.org
https://lists.gnupg.org/mailman/listinfo/gcrypt-devel