Re: RC5 slower than DES ?

New Message Reply About this list Date view Thread view Subject view Author view

Eric Young (eay@cryptsoft.com)
Thu, 12 Feb 1998 08:14:40 +1000 (EST)


On Wed, 11 Feb 1998, Hamdi Tounsi wrote:
> when benchmarking des and rc5 with the distributed.net client, i noticed
> that rc5 multiple encryptions with different keys runs at 1/3 the speed
> of DES.
> rc5 is much more simpler than des, so it must be the key sheduling for
> rc5 which is slower than des
> someone can benchmark separately the key sheduling and encryption ?

If they are doing multiple key rc5, what does this mean?
Is this 'tripple rc5' or some such construct? The rc5 key setup is about
2 times as expensive as DES but is basically not bad.

As for RC5 the cipher, it screams.
So, unless they are doing triple RC5, it should definitly be faster.

RC5, being rotation dependant, is quite relient on the C compiler
impementing ((r<<x)|(r>>(32-x)))&0xffffffff as rotate. gcc (for x86 at
least) does not do this. So for compilers like Visual-C, where there is
access to the rotate instruction, performance of C code is much better.
Even given this limitation, RC5 outperforms DES when implemented using a bad
compiler and the same language.

I'll append my numbers for RC5 speeds. Only the encrypt/decrypt has assember,
key setup is always C.

eric

586-100, linux, gcc+asm
RC5_32/12/16 set_key per sec = 27663.20 ( 36.149uS)
RC5_32/12/16 raw ecb bytes per sec = 4192876.80 ( 1.908uS)
RC5_32/12/16 cbc bytes per sec = 4097341.94 ( 1.952uS)
        set_key per sec = 57291.39 ( 17.455uS)
        DES raw ecb bytes per sec = 2259844.80 ( 3.540uS)
        DES cbc bytes per sec = 2228838.40 ( 3.589uS)
        DES ede cbc bytes per sec = 779980.80 ( 10.257uS)

586-100, linux, gcc+C
RC5_32/12/16 set_key per sec = 27790.00 ( 35.984uS)
RC5_32/12/16 raw ecb bytes per sec = 1751356.80 ( 4.568uS)
RC5_32/12/16 cbc bytes per sec = 1491660.80 ( 5.363uS)
        set_key per sec = 58351.96 ( 17.137uS)
        DES raw ecb bytes per sec = 1223388.80 ( 6.539uS)
        DES cbc bytes per sec = 998809.60 ( 8.010uS)
        DES ede cbc bytes per sec = 367411.20 ( 21.774uS)

ppro-200, linux gcc+asm
RC5_32/12/16 set_key per sec = 94299.60 ( 10.604uS)
RC5_32/12/16 raw ecb bytes per sec = 15399932.80 ( 0.519uS)
RC5_32/12/16 cbc bytes per sec = 13916036.87 ( 0.575uS)
        set_key per sec = 201036.30 ( 4.974uS)
        DES raw ecb bytes per sec = 4692650.40 ( 1.705uS)
        DES cbc bytes per sec = 4677836.80 ( 1.710uS)
        DES ede cbc bytes per sec = 1657036.80 ( 4.828uS)

ppro-200, linux gcc+C
RC5_32/12/16 set_key per sec = 94549.25 ( 10.576uS)
RC5_32/12/16 raw ecb bytes per sec = 6188752.00 ( 1.293uS)
RC5_32/12/16 cbc bytes per sec = 5051323.32 ( 1.584uS)
        set_key per sec = 206690.69 ( 4.838uS)
        DES raw ecb bytes per sec = 3357005.81 ( 2.383uS)
        DES cbc bytes per sec = 2991535.54 ( 2.674uS)
        DES ede cbc bytes per sec = 1119436.80 ( 7.146uS)


New Message Reply About this list Date view Thread view Subject view Author view

 
All trademarks and copyrights are the property of their respective owners.

Other Directory Sites: SeekWonder | Directory Owners Forum

The following archive was created by hippie-mail 7.98617-22 on Fri Aug 21 1998 - 17:14:54 ADT