>> Is there an option when making an app that uses OpenSSL to verify
>> that is uses Crypto Extensions (like checking a flag or something
>> like that) ?
> 
> With x86_64, ciphers like aes-128-cbc are much faster with AES-NI,
> so a simple benchmark:
> 
> openssl speed aes-128-cbc openssl speed -evp aes-128-cbc
> 
> will tell you if the code uses hardware acceleration, as it's only
> the EVP that is accelerated.
> 
> But when I've tested it on AArch64 with openssl-1.1.0-pre5 and
> current master (./configure no-shared no-engine) I'm getting
> 100524.03k vs 52172.12k/s in favour of the non-EVP version.
> 
> Is that really expected?

Depends on your system. Not all AArch64 processors were born equal,
some have crypto extensions, some don't, some have mighty pipelines,
some don't. The presented numbers suggest that you ended up on APM
X-Gene processor which doesn't. Is it a regression? In EVP mode it
uses NEON code path which is resistant to side-channel attacks, so
that you loose performance, but do gain security. In other words it is
expected. See even crypto/aes/asm/vpaes-armv8.pl for processor
comparison, compare even to crypto/aes/asm/aesv8-armx.pl.

> With 1.0.1 and 1.0.2 I'm getting around 100000k/s with and without 
> EVP, so that looks like a regression to me.

That's because there is no NEON AES code path in 1.0.2.

-- 
openssl-dev mailing list
To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-dev

Reply via email to