aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-06-02 13:18:16 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-06-02 13:18:16 +0200
commit09d6beee2496b6d8cd821e914522682cfd18a723 (patch)
tree2587bc4739a6dbb3d7bc89406591bf62e737d7d1
parent682b2273e851b478736255f500e019b0164751f8 (diff)
downloadffmpeg-09d6beee2496b6d8cd821e914522682cfd18a723.tar.gz
avutil/sha512: Reshuffle Maj() operands
This reduces dependancy chains and improves speed by about 2% Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavutil/sha512.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavutil/sha512.c b/libavutil/sha512.c
index 7ed4ea5478..445480cce1 100644
--- a/libavutil/sha512.c
+++ b/libavutil/sha512.c
@@ -91,7 +91,7 @@ static const uint64_t K512[80] = {
#define ror(value, bits) (((value) >> (bits)) | ((value) << (64 - (bits))))
#define Ch(x,y,z) (((x) & ((y) ^ (z))) ^ (z))
-#define Maj(x,y,z) ((((x) | (y)) & (z)) | ((x) & (y)))
+#define Maj(z,y,x) ((((x) | (y)) & (z)) | ((x) & (y)))
#define Sigma0_512(x) (ror((x), 28) ^ ror((x), 34) ^ ror((x), 39))
#define Sigma1_512(x) (ror((x), 14) ^ ror((x), 18) ^ ror((x), 41))