[PATCH 08/17] cipher:dilithium: Functions of poly for different DILITHIUM_MODE.
NIIBE Yutaka
gniibe at fsij.org
Sat Jun 28 05:44:45 CEST 2025
* cipher/dilithium-common.c (decompose): Make it into...
(decompose_88, decompose_32): ... these two functions.
(make_hint): Make it into...
(make_hint_88, make_hint_32): ... these two functions.
(use_hint): Make it into...
(use_hint_88, use_hint_32): ... these two functions.
(poly_decompose): Make it into...
(poly_decompose_88, poly_decompose_32): ... these two functions.
(poly_make_hint): Make it into...
(poly_make_hint_88, poly_make_hint_32): ... these two functions.
(poly_use_hint): Make it into...
(poly_use_hint_88, poly_use_hint_32): ... these two functions.
(rej_eta): Make it into...
(rej_eta_2, rej_eta_4): ... these two functions.
(poly_uniform_eta): Make it into...
(poly_uniform_eta_2, poly_uniform_eta_4): ... these two functions.
(POLY_UNIFORM_ETA_NBLOCKS): Make it into...
(POLY_UNIFORM_ETA_NBLOCKS_2, POLY_UNIFORM_ETA_NBLOCKS_4): ... these
two macros.
(poly_uniform_gamma1): Make it into...
(poly_uniform_gamma1_17, poly_uniform_gamma1_19): ... these two
functions.
(POLY_UNIFORM_GAMMA1_NBLOCKS): Make it into...
(POLY_UNIFORM_GAMMA1_NBLOCKS_17, POLY_UNIFORM_GAMMA1_NBLOCKS_19):
... these two macros.
(polyeta_pack): Make it into...
(polyeta_pack_2, polyeta_pack_4): ... these two functions.
(polyeta_unpack): Make it into...
(polyeta_unpack_2, polyeta_unpack_4): ... these two functions.
(polyz_pack): Make it into...
(polyz_pack_17, polyz_pack_19): ... these two functions.
(polyz_unpack): Make it into...
(polyz_unpack_17, polyz_unpack_19): ... these two functions.
(polyw1_pack): Make it into...
(polyw1_pack_88, polyw1_pack_32): ... these two functions.
--
GnuPG-bug-id: 7640
Signed-off-by: NIIBE Yutaka <gniibe at fsij.org>
---
cipher/dilithium-common.c | 371 ++++++++++++++++++++++++++++----------
1 file changed, 271 insertions(+), 100 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0008-cipher-dilithium-Functions-of-poly-for-different-DIL.patch
Type: text/x-patch
Size: 21652 bytes
Desc: not available
URL: <https://lists.gnupg.org/pipermail/gcrypt-devel/attachments/20250628/e3e3d8b7/attachment.bin>
More information about the Gcrypt-devel
mailing list