alistair23-linux/arch/x86/crypto
Johannes Goetzfried 4d6d6a2c85 crypto: cast5 - add x86_64/avx assembler implementation
This patch adds a x86_64/avx assembler implementation of the Cast5 block
cipher. The implementation processes sixteen blocks in parallel (four 4 block
chunk AVX operations). The table-lookups are done in general-purpose registers.
For small blocksizes the functions from the generic module are called. A good
performance increase is provided for blocksizes greater or equal to 128B.

Patch has been tested with tcrypt and automated filesystem tests.

Tcrypt benchmark results:

Intel Core i5-2500 CPU (fam:6, model:42, step:7)

cast5-avx-x86_64 vs. cast5-generic
64bit key:
size    ecb-enc ecb-dec cbc-enc cbc-dec ctr-enc ctr-dec
16B     0.99x   0.99x   1.00x   1.00x   1.02x   1.01x
64B     1.00x   1.00x   0.98x   1.00x   1.01x   1.02x
256B    2.03x   2.01x   0.95x   2.11x   2.12x   2.13x
1024B   2.30x   2.24x   0.95x   2.29x   2.35x   2.35x
8192B   2.31x   2.27x   0.95x   2.31x   2.39x   2.39x

128bit key:
size    ecb-enc ecb-dec cbc-enc cbc-dec ctr-enc ctr-dec
16B     0.99x   0.99x   1.00x   1.00x   1.01x   1.01x
64B     1.00x   1.00x   0.98x   1.01x   1.02x   1.01x
256B    2.17x   2.13x   0.96x   2.19x   2.19x   2.19x
1024B   2.29x   2.32x   0.95x   2.34x   2.37x   2.38x
8192B   2.35x   2.32x   0.95x   2.35x   2.39x   2.39x

Signed-off-by: Johannes Goetzfried <Johannes.Goetzfried@informatik.stud.uni-erlangen.de>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2012-08-01 17:47:30 +08:00
..
ablk_helper.c crypto: aes_ni - change to use shared ablk_* functions 2012-06-27 14:42:01 +08:00
aes-i586-asm_32.S
aes-x86_64-asm_64.S
aes_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
aesni-intel_asm.S crypto: aesni-intel - fix unaligned cbc decrypt for x86-32 2012-05-31 20:53:22 +10:00
aesni-intel_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
blowfish-x86_64-asm_64.S crypto: blowfish-x86_64 - improve x86_64 blowfish 4-way performance 2011-10-21 14:23:07 +02:00
blowfish_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
camellia-x86_64-asm_64.S crypto: camellia - add assembler implementation for x86_64 2012-03-14 17:25:56 +08:00
camellia_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
cast5-avx-x86_64-asm_64.S crypto: cast5 - add x86_64/avx assembler implementation 2012-08-01 17:47:30 +08:00
cast5_avx_glue.c crypto: cast5 - add x86_64/avx assembler implementation 2012-08-01 17:47:30 +08:00
crc32c-intel.c crypto: Add support for x86 cpuid auto loading for x86 crypto drivers 2012-01-26 16:48:10 -08:00
fpu.c crypto: aesni-intel - Merge with fpu.ko 2011-05-16 15:12:47 +10:00
ghash-clmulni-intel_asm.S
ghash-clmulni-intel_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
glue_helper.c crypto: serpent-sse2 - split generic glue code to new helper module 2012-06-27 14:42:01 +08:00
Makefile crypto: cast5 - add x86_64/avx assembler implementation 2012-08-01 17:47:30 +08:00
salsa20-i586-asm_32.S
salsa20-x86_64-asm_64.S
salsa20_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
serpent-avx-x86_64-asm_64.S crypto: serpent-sse2/avx - allow both to be built into kernel 2012-06-14 10:09:03 +08:00
serpent-sse2-i586-asm_32.S crypto: serpent-sse2 - change transpose_4x4 to only use integer instructions 2012-01-13 16:38:40 +11:00
serpent-sse2-x86_64-asm_64.S crypto: serpent-sse2 - change transpose_4x4 to only use integer instructions 2012-01-13 16:38:40 +11:00
serpent_avx_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
serpent_sse2_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
sha1_ssse3_asm.S crypto: sha1 - use Kbuild supplied flags for AVX test 2012-06-12 16:37:16 +08:00
sha1_ssse3_glue.c crypto: sha1 - use Kbuild supplied flags for AVX test 2012-06-12 16:37:16 +08:00
twofish-avx-x86_64-asm_64.S crypto: twofish-avx - remove useless instruction 2012-07-11 11:08:30 +08:00
twofish-i586-asm_32.S crypto: twofish-x86-asm - make assembler functions use twofish_ctx instead of crypto_tfm 2011-10-21 14:23:08 +02:00
twofish-x86_64-asm_64-3way.S crypto: twofish - add 3-way parallel x86_64 assembler implemention 2011-10-21 14:23:08 +02:00
twofish-x86_64-asm_64.S crypto: twofish-x86-asm - make assembler functions use twofish_ctx instead of crypto_tfm 2011-10-21 14:23:08 +02:00
twofish_avx_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
twofish_glue.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00
twofish_glue_3way.c crypto: arch/x86 - cleanup - remove unneeded crypto_alg.cra_list initializations 2012-08-01 17:47:27 +08:00