Here are speed benchmarks for some of the most commonly used cryptographic algorithms. All were coded in C++, compiled with Microsoft Visual C++ 2005 SP1 (whole program optimization, optimize for speed), and ran on an Intel Core 2 1.83 GHz processor under Windows Vista in 32-bit mode. x86/MMX/SSE2 assembly language routines were used for integer arithmetic, AES, VMAC, Sosemanuk, Panama, Salsa20, SHA-256, SHA-512, Tiger, and Whirlpool. (OpenMP support was disabled so only one core of the CPU was used for this benchmark.) The results from the same binary running on an Intel Pentium 4 (Prescott) CPU are available here.
Also available are benchmarks that ran on an AMD Opteron 8354 2.2 GHz processor under Linux. Those were compiled with GCC 4.1.2 using -O3 optimization, and x86-64/MMX/SSE2 assembly language routines were used for integer arithmetic, AES, VMAC, Sosemanuk, Panama, Salsa20, SHA-256, and Whirlpool.
Algorithm | MiB/Second | Cycles Per Byte | Microseconds to Setup Key and IV | Cycles to Setup Key and IV |
---|---|---|---|---|
AES/GCM (2K tables) | 102 | 17.2 | 2.946 | 5391 |
AES/GCM (64K tables) | 108 | 16.1 | 11.546 | 21130 |
AES/CCM | 61 | 28.6 | 0.888 | 1625 |
AES/EAX | 61 | 28.8 | 1.757 | 3216 |
GMAC(AES) (2K tables) | 417 | 4.2 | 2.944 | 5388 |
GMAC(AES) (64K tables) | 540 | 3.2 | 11.523 | 21088 |
VMAC(AES)-64 | 1519 | 1.1 | 3.133 | 5734 |
VMAC(AES)-128 | 779 | 2.2 | 3.738 | 6841 |
HMAC(SHA-1) | 147 | 11.9 | 0.509 | 932 |
Two-Track-MAC | 105 | 16.6 | 0.041 | 75 |
CMAC(AES) | 109 | 16.1 | 0.600 | 1098 |
DMAC(AES) | 109 | 16.0 | 1.761 | 3223 |
CRC32 | 253 | 6.9 | ||
Adler32 | 920 | 1.9 | ||
MD5 | 255 | 6.8 | ||
SHA-1 | 153 | 11.4 | ||
SHA-256 | 111 | 15.8 | ||
SHA-512 | 99 | 17.7 | ||
Tiger | 214 | 8.1 | ||
Whirlpool | 57 | 30.5 | ||
RIPEMD-160 | 106 | 16.5 | ||
RIPEMD-320 | 110 | 15.9 | ||
RIPEMD-128 | 153 | 11.4 | ||
RIPEMD-256 | 158 | 11.1 | ||
Panama-LE | 843 | 2.1 | 1.695 | 3103 |
Panama-BE | 397 | 4.4 | 2.703 | 4946 |
Salsa20 | 408 | 4.3 | 0.390 | 714 |
Salsa20/12 | 643 | 2.7 | 0.483 | 884 |
Salsa20/8 | 887 | 2.0 | 0.481 | 881 |
Sosemanuk | 727 | 2.4 | 1.240 | 2269 |
MARC4 | 126 | 13.9 | 2.690 | 4923 |
SEAL-3.0-LE | 375 | 4.7 | 63.697 | 116566 |
WAKE-OFB-LE | 197 | 8.9 | 2.816 | 5153 |
AES/CTR (128-bit key) | 139 | 12.6 | 0.698 | 1277 |
AES/CTR (192-bit key) | 113 | 15.4 | 0.707 | 1293 |
AES/CTR (256-bit key) | 96 | 18.2 | 0.756 | 1383 |
AES/CBC (128-bit key) | 109 | 16.0 | 0.569 | 1041 |
AES/CBC (192-bit key) | 92 | 18.9 | 0.572 | 1046 |
AES/CBC (256-bit key) | 80 | 21.7 | 0.619 | 1133 |
AES/OFB (128-bit key) | 103 | 16.9 | 0.702 | 1285 |
AES/CFB (128-bit key) | 108 | 16.1 | 0.926 | 1695 |
AES/ECB (128-bit key) | 109 | 16.0 | 0.253 | 462 |
Camellia/CTR (128-bit key) | 48 | 36.3 | 0.632 | 1156 |
Camellia/CTR (256-bit key) | 37 | 47.4 | 0.696 | 1273 |
Twofish/CTR | 59 | 29.4 | 7.716 | 14121 |
Serpent/CTR | 32 | 54.7 | 1.197 | 2191 |
CAST-256/CTR | 37 | 47.1 | 2.659 | 4865 |
RC6/CTR | 101 | 17.3 | 2.802 | 5128 |
MARS/CTR | 47 | 37.2 | 3.516 | 6435 |
SHACAL-2/CTR (128-bit key) | 53 | 32.9 | 0.896 | 1639 |
SHACAL-2/CTR (512-bit key) | 54 | 32.6 | 0.919 | 1681 |
DES/CTR | 32 | 54.7 | 8.372 | 15320 |
DES-XEX3/CTR | 29 | 60.6 | 8.309 | 15206 |
DES-EDE3/CTR | 13 | 134.5 | 27.317 | 49989 |
IDEA/CTR | 35 | 49.9 | 0.698 | 1277 |
RC5 (r=16) | 75 | 23.4 | 2.549 | 4665 |
Blowfish/CTR | 58 | 30.0 | 62.683 | 114710 |
TEA/CTR | 27 | 65.1 | 0.638 | 1167 |
XTEA/CTR | 26 | 67.4 | 0.636 | 1165 |
CAST-128/CTR | 55 | 31.9 | 1.008 | 1844 |
SKIPJACK/CTR | 10 | 180.5 | 3.456 | 6324 |
SEED/CTR (1/2 K table) | 29 | 59.2 | 0.762 | 1394 |
Operation | Milliseconds/Operation | Megacycles/Operation |
---|---|---|
RSA 1024 Encryption | 0.08 | 0.14 |
RSA 1024 Decryption | 1.46 | 2.68 |
LUC 1024 Encryption | 0.08 | 0.14 |
LUC 1024 Decryption | 2.49 | 4.55 |
DLIES 1024 Encryption | 0.85 | 1.56 |
DLIES 1024 Encryption with precomputation | 1.49 | 2.72 |
DLIES 1024 Decryption | 1.18 | 2.17 |
LUCELG 512 Encryption | 0.58 | 1.05 |
LUCELG 512 Encryption with precomputation | 0.58 | 1.05 |
LUCELG 512 Decryption | 0.65 | 1.18 |
RSA 2048 Encryption | 0.16 | 0.29 |
RSA 2048 Decryption | 6.08 | 11.12 |
LUC 2048 Encryption | 0.18 | 0.33 |
LUC 2048 Decryption | 9.89 | 18.10 |
DLIES 2048 Encryption | 4.11 | 7.52 |
DLIES 2048 Encryption with precomputation | 4.54 | 8.30 |
DLIES 2048 Decryption | 3.86 | 7.07 |
LUCELG 1024 Encryption | 1.89 | 3.45 |
LUCELG 1024 Encryption with precomputation | 1.88 | 3.45 |
LUCELG 1024 Decryption | 1.73 | 3.17 |
RSA 1024 Signature | 1.48 | 2.71 |
RSA 1024 Verification | 0.07 | 0.13 |
RW 1024 Signature | 2.03 | 3.72 |
RW 1024 Verification | 0.05 | 0.08 |
LUC 1024 Signature | 2.49 | 4.56 |
LUC 1024 Verification | 0.08 | 0.14 |
NR 1024 Signature | 0.45 | 0.82 |
NR 1024 Signature with precomputation | 0.42 | 0.76 |
NR 1024 Verification | 0.51 | 0.92 |
NR 1024 Verification with precomputation | 0.70 | 1.29 |
DSA 1024 Signature | 0.45 | 0.83 |
DSA 1024 Signature with precomputation | 0.42 | 0.78 |
DSA 1024 Verification | 0.52 | 0.94 |
DSA 1024 Verification with precomputation | 0.67 | 1.23 |
LUC-HMP 512 Signature | 0.58 | 1.06 |
LUC-HMP 512 Signature with precomputation | 0.58 | 1.06 |
LUC-HMP 512 Verification | 0.60 | 1.09 |
LUC-HMP 512 Verification with precomputation | 0.60 | 1.09 |
ESIGN 1023 Signature | 0.22 | 0.40 |
ESIGN 1023 Verification | 0.07 | 0.12 |
ESIGN 1536 Signature | 0.38 | 0.70 |
ESIGN 1536 Verification | 0.14 | 0.26 |
RSA 2048 Signature | 6.05 | 11.06 |
RSA 2048 Verification | 0.16 | 0.29 |
RW 2048 Signature | 7.37 | 13.49 |
RW 2048 Verification | 0.10 | 0.18 |
LUC 2048 Signature | 9.92 | 18.16 |
LUC 2048 Verification | 0.18 | 0.32 |
NR 2048 Signature | 2.09 | 3.83 |
NR 2048 Signature with precomputation | 0.93 | 1.71 |
NR 2048 Verification | 2.39 | 4.37 |
NR 2048 Verification with precomputation | 1.57 | 2.88 |
LUC-HMP 1024 Signature | 1.91 | 3.50 |
LUC-HMP 1024 Signature with precomputation | 1.92 | 3.51 |
LUC-HMP 1024 Verification | 2.02 | 3.70 |
LUC-HMP 1024 Verification with precomputation | 1.97 | 3.60 |
ESIGN 2046 Signature | 0.48 | 0.88 |
ESIGN 2046 Verification | 0.15 | 0.28 |
XTR-DH 171 Key-Pair Generation | 0.78 | 1.43 |
XTR-DH 171 Key Agreement | 1.55 | 2.83 |
XTR-DH 342 Key-Pair Generation | 1.87 | 3.43 |
XTR-DH 342 Key Agreement | 3.74 | 6.85 |
DH 1024 Key-Pair Generation | 0.45 | 0.82 |
DH 1024 Key-Pair Generation with precomputation | 0.83 | 1.51 |
DH 1024 Key Agreement | 1.18 | 2.16 |
DH 2048 Key-Pair Generation | 2.14 | 3.92 |
DH 2048 Key-Pair Generation with precomputation | 2.40 | 4.39 |
DH 2048 Key Agreement | 3.84 | 7.03 |
LUCDIF 512 Key-Pair Generation | 0.30 | 0.55 |
LUCDIF 512 Key-Pair Generation with precomputation | 0.30 | 0.55 |
LUCDIF 512 Key Agreement | 0.64 | 1.18 |
LUCDIF 1024 Key-Pair Generation | 0.98 | 1.79 |
LUCDIF 1024 Key-Pair Generation with precomputation | 0.98 | 1.79 |
LUCDIF 1024 Key Agreement | 1.73 | 3.17 |
MQV 1024 Key-Pair Generation | 0.43 | 0.78 |
MQV 1024 Key-Pair Generation with precomputation | 0.40 | 0.73 |
MQV 1024 Key Agreement | 0.91 | 1.66 |
MQV 2048 Key-Pair Generation | 2.09 | 3.83 |
MQV 2048 Key-Pair Generation with precomputation | 0.92 | 1.68 |
MQV 2048 Key Agreement | 3.97 | 7.27 |
ECIES over GF(p) 256 Encryption | 5.65 | 10.34 |
ECIES over GF(p) 256 Encryption with precomputation | 4.21 | 7.70 |
ECIES over GF(p) 256 Decryption | 3.98 | 7.29 |
ECDSA over GF(p) 256 Signature | 2.88 | 5.27 |
ECDSA over GF(p) 256 Signature with precomputation | 2.14 | 3.92 |
ECDSA over GF(p) 256 Verification | 8.53 | 15.61 |
ECDSA over GF(p) 256 Verification with precomputation | 3.58 | 6.56 |
ECDHC over GF(p) 256 Key-Pair Generation | 2.87 | 5.25 |
ECDHC over GF(p) 256 Key-Pair Generation with precomputation | 2.11 | 3.87 |
ECDHC over GF(p) 256 Key Agreement | 2.82 | 5.17 |
ECMQVC over GF(p) 256 Key-Pair Generation | 2.84 | 5.20 |
ECMQVC over GF(p) 256 Key-Pair Generation with precomputation | 2.19 | 4.01 |
ECMQVC over GF(p) 256 Key Agreement | 8.31 | 15.21 |
ECIES over GF(2^n) 233 Encryption | 21.17 | 38.74 |
ECIES over GF(2^n) 233 Encryption with precomputation | 6.08 | 11.13 |
ECIES over GF(2^n) 233 Decryption | 12.15 | 22.23 |
ECDSA over GF(2^n) 233 Signature | 10.62 | 19.43 |
ECDSA over GF(2^n) 233 Signature with precomputation | 3.08 | 5.64 |
ECDSA over GF(2^n) 233 Verification | 12.80 | 23.43 |
ECDSA over GF(2^n) 233 Verification with precomputation | 5.30 | 9.69 |
ECDHC over GF(2^n) 233 Key-Pair Generation | 10.51 | 19.23 |
ECDHC over GF(2^n) 233 Key-Pair Generation with precomputation | 3.03 | 5.55 |
ECDHC over GF(2^n) 233 Key Agreement | 10.72 | 19.61 |
ECMQVC over GF(2^n) 233 Key-Pair Generation | 10.49 | 19.20 |
ECMQVC over GF(2^n) 233 Key-Pair Generation with precomputation | 3.04 | 5.57 |
ECMQVC over GF(2^n) 233 Key Agreement | 13.20 | 24.16 |
modulus | exponent |
---|---|
1024 | 164 |
2048 | 226 |