Yesudeep Mangalapilly | a4453c6 | 2011-08-11 12:03:37 +0530 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | |
| 3 | echo "int2bytes speed test" |
| 4 | echo "python2.5" |
| 5 | python2.5 -mtimeit -s'from rsa.transform import int2bytes; n = 1<<4096' 'int2bytes(n)' |
Yesudeep Mangalapilly | 8132524 | 2011-08-12 13:06:51 +0530 | [diff] [blame] | 6 | python2.5 -mtimeit -s'from rsa.transform import _int2bytes; n = 1<<4096' '_int2bytes(n)' |
Yesudeep Mangalapilly | a4453c6 | 2011-08-11 12:03:37 +0530 | [diff] [blame] | 7 | echo "python2.6" |
Yesudeep Mangalapilly | 8132524 | 2011-08-12 13:06:51 +0530 | [diff] [blame] | 8 | python2.6 -mtimeit -s'from rsa.transform import int2bytes; n = 1<<4096' 'int2bytes(n, 516)' |
| 9 | python2.6 -mtimeit -s'from rsa.transform import _int2bytes; n = 1<<4096' '_int2bytes(n, 516)' |
Yesudeep Mangalapilly | a4453c6 | 2011-08-11 12:03:37 +0530 | [diff] [blame] | 10 | echo "python2.7" |
| 11 | python2.7 -mtimeit -s'from rsa.transform import int2bytes; n = 1<<4096' 'int2bytes(n)' |
Yesudeep Mangalapilly | 8132524 | 2011-08-12 13:06:51 +0530 | [diff] [blame] | 12 | python2.7 -mtimeit -s'from rsa.transform import _int2bytes; n = 1<<4096' '_int2bytes(n)' |
Yesudeep Mangalapilly | a4453c6 | 2011-08-11 12:03:37 +0530 | [diff] [blame] | 13 | echo "python3.2" |
| 14 | python3 -mtimeit -s'from rsa.transform import int2bytes; n = 1<<4096' 'int2bytes(n)' |
Yesudeep Mangalapilly | 8132524 | 2011-08-12 13:06:51 +0530 | [diff] [blame] | 15 | python3 -mtimeit -s'from rsa.transform import _int2bytes; n = 1<<4096' '_int2bytes(n)' |
Yesudeep Mangalapilly | 167f488 | 2011-08-12 13:12:06 +0530 | [diff] [blame^] | 16 | echo "pypy" |
| 17 | pypy -mtimeit -s'from rsa.transform import int2bytes; n = 1<<4096' 'int2bytes(n)' |
| 18 | pypy -mtimeit -s'from rsa.transform import _int2bytes; n = 1<<4096' '_int2bytes(n)' |
Yesudeep Mangalapilly | 8132524 | 2011-08-12 13:06:51 +0530 | [diff] [blame] | 19 | |