diff options
author | Daniel P. Berrange <berrange@redhat.com> | 2017-08-03 15:24:13 +0100 |
---|---|---|
committer | Niels Möller <nisse@lysator.liu.se> | 2017-08-26 09:29:20 +0200 |
commit | 5c78bb737c553f2064271f1a7c4768b88a09b665 (patch) | |
tree | 7ce699123bab2df70527f131bfc04cfea3ba4bcb /nettle-internal.h | |
parent | dcda81d796de2f4a16fd7e9e7a5d07baa288f147 (diff) | |
download | nettle-5c78bb737c553f2064271f1a7c4768b88a09b665.tar.gz |
examples: convert nettle-benchmark to use openssl EVP APIs
The nettle-benchmark program currently uses the openssl low level
cipher APIs for benchmarking. This means it always runs the generic
software implementation, never able to take advantage of impls
optimized for new hardware (eg AES-NI).
Rewriting it to use the higher EVP APIs means we can use the same
code for all ciphers, and automatically trigger hardware optimized
versions, giving a fairer comparison against openssl as commonly
used in applications.
Use of the generic openssl impl can still be forced by setting an
env variable OPENSSL_ia32cap="~0x200000200000000"
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Diffstat (limited to 'nettle-internal.h')
-rw-r--r-- | nettle-internal.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/nettle-internal.h b/nettle-internal.h index 9c4c699d..0b0d25c9 100644 --- a/nettle-internal.h +++ b/nettle-internal.h @@ -79,6 +79,7 @@ extern const struct nettle_aead nettle_salsa20r12; /* Glue to openssl, for comparative benchmarking. Code in * examples/nettle-openssl.c. */ +extern void nettle_openssl_init(void); extern const struct nettle_cipher nettle_openssl_aes128; extern const struct nettle_cipher nettle_openssl_aes192; extern const struct nettle_cipher nettle_openssl_aes256; |