All of lore.kernel.org
 help / color / mirror / Atom feed
* comparison of the AF_ALG interface with the /dev/crypto
@ 2011-08-28 13:17 Nikos Mavrogiannopoulos
  2011-08-28 20:35 ` David Miller
                   ` (2 more replies)
  0 siblings, 3 replies; 29+ messages in thread
From: Nikos Mavrogiannopoulos @ 2011-08-28 13:17 UTC (permalink / raw)
  To: cryptodev-linux-devel, linux-crypto, linux-kernel

Hello,
  I've compared the cryptodev [0] and AF_ALG interfaces in terms of
performance [1]. I've put the results, as well as the benchmarks used
in: http://home.gna.org/cryptodev-linux/comparison.html

The benchmark idea was to test the speed of initialization, encryption
and deinitiation, as well as the encryption speed alone. These are the
most common use cases of the frameworks (i.e. how they would be used by 
a cryptographic library).

The AF_ALG appears to have poor performance comparing to cryptodev. Note
that the test with software AES is not really indicative because the
cost of software encryption masks the overhead of the framework. The
difference is clearly seen in the NULL cipher that has no cost (as one
would expect from a hardware cipher accelerator).

Given my benchmarks have no issues, it is not apparent to me why one
should use AF_ALG instead of cryptodev. I do not know though why AF_ALG
performs so poor. I'd speculate by blaming it on the usage of the socket
API and the number of system calls required.

regards,
Nikos

[0]. http://home.gna.org/cryptodev-linux/
[1]. Both intend to provide user-space with high-bandwidth hardware 
accelerated ciphers, thus performance seems a rational to compare.

^ permalink raw reply	[flat|nested] 29+ messages in thread

end of thread, other threads:[~2011-09-01 16:19 UTC | newest]

Thread overview: 29+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-28 13:17 comparison of the AF_ALG interface with the /dev/crypto Nikos Mavrogiannopoulos
2011-08-28 20:35 ` David Miller
2011-08-29  7:32   ` Nikos Mavrogiannopoulos
2011-08-29 16:09     ` David Miller
2011-08-30 16:33 ` [Cryptodev-linux-devel] " Phil Sutter
2011-09-01  2:15 ` Herbert Xu
2011-09-01  2:15   ` Herbert Xu
2011-09-01  6:26   ` Nikos Mavrogiannopoulos
2011-09-01  6:43     ` Herbert Xu
2011-09-01  6:43       ` Herbert Xu
2011-09-01  6:54       ` Nikos Mavrogiannopoulos
2011-09-01  6:56         ` Herbert Xu
2011-09-01  6:56           ` Herbert Xu
2011-09-01 13:39   ` Phil Sutter
2011-09-01 13:39     ` Phil Sutter
2011-09-01 14:14     ` Herbert Xu
2011-09-01 14:14       ` Herbert Xu
2011-09-01 14:56       ` Nikos Mavrogiannopoulos
2011-09-01 14:59         ` Herbert Xu
2011-09-01 14:59           ` Herbert Xu
2011-09-01 15:06           ` Nikos Mavrogiannopoulos
2011-09-01 15:08             ` Herbert Xu
2011-09-01 15:08               ` Herbert Xu
2011-09-01 15:32             ` David Miller
2011-09-01 16:19               ` Nikos Mavrogiannopoulos
2011-09-01 15:09       ` Phil Sutter
2011-09-01 15:09         ` Phil Sutter
2011-09-01 15:13         ` Herbert Xu
2011-09-01 15:13           ` Herbert Xu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.