summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJussi Kivilinna <jussi.kivilinna@mbnet.fi>2012-08-28 16:49:28 +0300
committerHerbert Xu <herbert@gondor.apana.org.au>2012-09-07 04:17:06 +0800
commit71604e34b2d213e0b07a7e0186200b71c4c3abc9 (patch)
treea3aa2e2fb22697d36a86657e81e46249e2da968d
parent463527db59965ff5d93987219fd3a2ebe3ee39e0 (diff)
downloadlinux-crypto-71604e34b2d213e0b07a7e0186200b71c4c3abc9.tar.gz
linux-crypto-71604e34b2d213e0b07a7e0186200b71c4c3abc9.zip
Revert "[CRYPTO] cast6: inline bloat--"
This reverts commit 4be14bb3a075b8a2b26c62c97cdeda71d933d590. Above commit caused performance regression for CAST6. Reverting gives following increase in tcrypt speed tests (revert-vs-old ratios). AMD Phenom II X6 1055T, x86-64: size ecb cbc ctr lrw xts enc dec enc dec enc dec enc dec enc dec 16b 1.15x 1.17x 1.16x 1.17x 1.16x 1.16x 1.14x 1.19x 1.05x 1.07x 64b 1.19x 1.23x 1.20x 1.22x 1.19x 1.19x 1.16x 1.24x 1.12x 1.12x 256b 1.21x 1.24x 1.22x 1.24x 1.20x 1.20x 1.17x 1.21x 1.16x 1.14x 1kb 1.21x 1.25x 1.22x 1.24x 1.21x 1.21x 1.18x 1.22x 1.17x 1.15x 8kb 1.21x 1.25x 1.22x 1.24x 1.21x 1.21x 1.18x 1.22x 1.18x 1.15x Cc: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
-rw-r--r--crypto/cast6_generic.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/cast6_generic.c b/crypto/cast6_generic.c
index dc9309d7..1acd2f1c 100644
--- a/crypto/cast6_generic.c
+++ b/crypto/cast6_generic.c
@@ -370,7 +370,7 @@ static const u8 Tr[4][8] = {
};
/* forward octave */
-static void W(u32 *key, unsigned int i)
+static inline void W(u32 *key, unsigned int i)
{
u32 I;
key[6] ^= F1(key[7], Tr[i % 4][0], Tm[i][0]);
@@ -434,7 +434,7 @@ int cast6_setkey(struct crypto_tfm *tfm, const u8 *key, unsigned int keylen)
EXPORT_SYMBOL_GPL(cast6_setkey);
/*forward quad round*/
-static void Q(u32 *block, u8 *Kr, u32 *Km)
+static inline void Q(u32 *block, u8 *Kr, u32 *Km)
{
u32 I;
block[2] ^= F1(block[3], Kr[0], Km[0]);
@@ -444,7 +444,7 @@ static void Q(u32 *block, u8 *Kr, u32 *Km)
}
/*reverse quad round*/
-static void QBAR(u32 *block, u8 *Kr, u32 *Km)
+static inline void QBAR(u32 *block, u8 *Kr, u32 *Km)
{
u32 I;
block[3] ^= F1(block[0], Kr[3], Km[3]);