diff options
author | lloyd <[email protected]> | 2009-08-12 18:38:15 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2009-08-12 18:38:15 +0000 |
commit | 690e9fc77872f253004c37d4c6a0707f1a3f1856 (patch) | |
tree | ff924fe9f89c2b4a731f3b1e58b9b73b10587176 /src/benchmark | |
parent | 1c9b4fda79951b1d0cd3c49ad8db8549cf9d9444 (diff) |
In benchmark.cpp, use encrypt_n when benchmarking block ciphers
Diffstat (limited to 'src/benchmark')
-rw-r--r-- | src/benchmark/benchmark.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/benchmark/benchmark.cpp b/src/benchmark/benchmark.cpp index 01e3b94f3..3bbc1f883 100644 --- a/src/benchmark/benchmark.cpp +++ b/src/benchmark/benchmark.cpp @@ -57,8 +57,7 @@ bench_block_cipher(BlockCipher* block_cipher, while(nanoseconds_used < nanoseconds_max) { - for(u32bit i = 0; i != in_blocks; ++i) - block_cipher->encrypt(buf + block_cipher->BLOCK_SIZE * i); + block_cipher->encrypt_n(buf, buf, in_blocks); ++reps; nanoseconds_used = timer.clock() - start; |