-
Notifications
You must be signed in to change notification settings - Fork 19
Use of OpenSSL command looks slow #4
Description
We have been using SimpleAES and I noticed it was using a process to run OpenSSL to do the encryption. We noticed the encryption seeming slow so I created a quick benchmark to see how the speed of this compares to using pycrypto.
The results of the benchmark against the latest version of SimpleAES does not look good:
| name | rank | runs | mean | sd | timesBaseline |
|---|---|---|---|---|---|
| pycrypto aes | 1 | 10 | 0.02799 | 0.004236 | 1.0 |
| pycrypto blowfish | 2 | 10 | 0.1362 | 0.01185 | 4.86693156086 |
| simpleaes | 3 | 10 | 6.488 | 0.228 | 231.818900462 |
Each of the above 30 runs were run in random, non-consecutive order by
benchmark v0.1.5 (http://jspi.es/benchmark) with Python 2.7.2
Darwin-12.3.0-x86_64 on 2013-05-29 09:47:26.
Running the same benchmark against SimpleAES==0.1 looks much better:
| name | rank | runs | mean | sd | timesBaseline |
|---|---|---|---|---|---|
| pycrypto aes | 1 | 10 | 0.02647 | 0.0002615 | 1.0 |
| simpleaes | 2 | 10 | 0.08313 | 0.001742 | 3.14058289017 |
| pycrypto blowfish | 3 | 10 | 0.1234 | 0.001254 | 4.66106763515 |
Each of the above 30 runs were run in random, non-consecutive order by
benchmark v0.1.5 (http://jspi.es/benchmark) with Python 2.7.2
Darwin-12.3.0-x86_64 on 2013-05-29 09:45:26.
My suspicion is that it is not OpenSSL that is slow but the overhead of starting a new sub process to run OpenSSL is slower