Re: [PATCH] mpi:ec: Use ec_mulm_lli in _gcry_mpi_ec_get_affine.

NIIBE Yutaka via Gcrypt-devel <[email protected]> Wed, 14 May 2025 11:32:07 +0900
Newsgroups gmane.comp.encryption.gpg.libgcrypt.devel
Message-ID <[email protected]>
Werner Koch <[email protected]> wrote:
> On Tue, 13 May 2025 09:28, NIIBE Yutaka said:
>> * mpi/ec.c (_gcry_mpi_ec_get_affine): Fix for possible leak.
>
> BTW, Do we have benchmarks for these LLI changes.

I used standard one of libgcrypt/tests/benchmark.  For 64-bit
architectures, changes resulted better; This is due to the improvements
with the code paths of LLI version (_gcry_mpih_powm_lli uses Montgomery
exponentiation, mpi_ec_mul_point_lli has optimization with affine
coordinates).

The approach taken for those improvements could be applied to existing
generic code paths, if done carefully.  This... is left as an exercise
for the hackers.
--