RPi上AES加密速度
閒著沒事來做個AES加密速度比較,用 RPi 小小的ARM11和Intel i5來比XD (簡直是螞蟻對上大象)
指令:
16bytes相差約18.7倍,8192bytes相差約9倍。比我想像中快嘛!
要不要在標題上下【無用】呢?
指令:
openssl speed -evp aes-128-cbc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> openssl speed aes-128-cbc | |
Doing aes-128 cbc 41943040 times on 16 size blocks: 41943040 aes-128 cbc's in 5.12s | |
Doing aes-128 cbc 10485760 times on 64 size blocks: 10485760 aes-128 cbc's in 4.67s | |
Doing aes-128 cbc 2621440 times on 256 size blocks: 2621440 aes-128 cbc's in 4.58s | |
Doing aes-128 cbc 655360 times on 1024 size blocks: 655360 aes-128 cbc's in 4.61s | |
Doing aes-128 cbc 81920 times on 8192 size blocks: 81920 aes-128 cbc's in 4.61s | |
OpenSSL 0.9.8h 28 May 2008 | |
built on: Fri Aug 22 19:47:15 2008 | |
options:bn(64,32) md2(int) rc4(idx,int) des(ptr,risc1,16,long) aes(partial) idea | |
(int) blowfish(idx) | |
compiler: gcc -DL_ENDIAN -DDSO_WIN32 -fomit-frame-pointer -O3 -march=i486 -Wall | |
-DBN_ASM -DMD5_ASM -DSHA1_ASM -DOPENSSL_BN_ASM_PART_WORDS -DOPENSSL_NO_CAMELLIA | |
-DOPENSSL_NO_SEED -DOPENSSL_NO_RC5 -DOPENSSL_NO_MDC2 -DOPENSSL_NO_TLSEXT -DOPENS | |
SL_NO_CMS -DOPENSSL_NO_KRB5 -DOPENSSL_NO_DYNAMIC_ENGINE | |
available timing options: TIMEB HZ=1000 | |
timing function used: ftime | |
The 'numbers' are in 1000s of bytes per second processed. | |
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes | |
aes-128 cbc 131072.00k 143794.44k 146366.12k 145698.79k 145698.79k |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> openssl speed aes-128-cbc | |
pi@raspberrypi ~ $ openssl speed -evp aes-128-cbc | |
Doing aes-128-cbc for 3s on 16 size blocks: 1302796 aes-128-cbc's in 2.98s | |
Doing aes-128-cbc for 3s on 64 size blocks: 562392 aes-128-cbc's in 2.98s | |
Doing aes-128-cbc for 3s on 256 size blocks: 171325 aes-128-cbc's in 2.98s | |
Doing aes-128-cbc for 3s on 1024 size blocks: 43886 aes-128-cbc's in 2.88s | |
Doing aes-128-cbc for 3s on 8192 size blocks: 5755 aes-128-cbc's in 2.98s | |
OpenSSL 1.0.1e 11 Feb 2013 | |
built on: Sun Mar 24 12:44:00 UTC 2013 | |
options:bn(64,32) rc4(ptr,char) des(idx,cisc,16,long) aes(partial) blowfish(ptr) | |
compiler: gcc -fPIC -DOPENSSL_PIC -DZLIB -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -DL_ENDIAN -DTERMIO -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -Wl,-z,relro -Wa,--noexecstack -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DGHASH_ASM | |
The 'numbers' are in 1000s of bytes per second processed. | |
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes | |
aes-128-cbc 6994.88k 12078.22k 14717.85k 15603.91k 15820.46k |
16bytes相差約18.7倍,8192bytes相差約9倍。比我想像中快嘛!
要不要在標題上下【無用】呢?
Comments
Post a Comment