[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 03/17] crypto: Assume blocksize is a power of 2
From: |
Daniel P . Berrangé |
Subject: |
Re: [PATCH 03/17] crypto: Assume blocksize is a power of 2 |
Date: |
Mon, 17 Aug 2020 17:51:23 +0100 |
User-agent: |
Mutt/1.14.5 (2020-06-23) |
On Wed, Aug 12, 2020 at 08:25:23PM -0700, Richard Henderson wrote:
> The check in the encode/decode path using full division has a
> noticeable amount of overhead. By asserting the blocksize is
> a power of 2, we can reduce this check to a mask.
>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
> crypto/cipher-builtin.c | 4 ++--
> crypto/cipher-gcrypt.c | 5 +++--
> crypto/cipher-nettle.c | 5 +++--
> crypto/cipher.c | 1 +
> 4 files changed, 9 insertions(+), 6 deletions(-)
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
[PATCH 02/17] crypto: Move QCryptoCipherDriver typedef to qemu/typedefs.h, Richard Henderson, 2020/08/12
[PATCH 03/17] crypto: Assume blocksize is a power of 2, Richard Henderson, 2020/08/12
- Re: [PATCH 03/17] crypto: Assume blocksize is a power of 2,
Daniel P . Berrangé <=
[PATCH 04/17] crypto: Rename cipher include files to .inc.c, Richard Henderson, 2020/08/12
[PATCH 05/17] crypto: Remove redundant includes, Richard Henderson, 2020/08/12
[PATCH 06/17] crypto/nettle: Fix xts_encrypt arguments, Richard Henderson, 2020/08/12
[PATCH 07/17] crypto: Use the correct const type for driver, Richard Henderson, 2020/08/12