diff options
author | lloyd <[email protected]> | 2009-11-17 07:20:51 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2009-11-17 07:20:51 +0000 |
commit | 7a24783fd58b21e1ea59615025806663e5f231eb (patch) | |
tree | b77c685e0b54f82890947009631461bcfe5b6880 /src/benchmark/benchmark.h | |
parent | e00b46cf9c1dcb364ebb7d5968d6ff9dcd600c4e (diff) | |
parent | 471847e2148776e62e4f580ade95572fc525c751 (diff) |
propagate from branch 'net.randombit.botan' (head 0ac5a29496b4e50775827d9655c064f6d1c98813)
to branch 'net.randombit.botan.c++0x' (head 3232da044d41756582b53da9d14c3ac07e9b2916)
Diffstat (limited to 'src/benchmark/benchmark.h')
-rw-r--r-- | src/benchmark/benchmark.h | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/src/benchmark/benchmark.h b/src/benchmark/benchmark.h index 272cfdfa2..a9c3fc01e 100644 --- a/src/benchmark/benchmark.h +++ b/src/benchmark/benchmark.h @@ -1,6 +1,6 @@ /** * Runtime benchmarking -* (C) 2008 Jack Lloyd +* (C) 2008-2009 Jack Lloyd * * Distributed under the terms of the Botan license */ @@ -9,35 +9,12 @@ #define BOTAN_RUNTIME_BENCHMARK_H__ #include <botan/algo_factory.h> -#include <botan/timer.h> #include <botan/rng.h> #include <map> #include <string> -/** -* Choose some sort of default timer implementation to use, since some -* (like hardware tick counters and current Win32 timer) are not -* reliable for benchmarking. -*/ -#if defined(BOTAN_HAS_TIMER_POSIX) - #include <botan/tm_posix.h> -#elif defined(BOTAN_HAS_TIMER_UNIX) - #include <botan/tm_unix.h> -#endif - namespace Botan { -#if defined(BOTAN_HAS_TIMER_POSIX) - typedef POSIX_Timer Default_Benchmark_Timer; -#elif defined(BOTAN_HAS_TIMER_UNIX) - typedef Unix_Timer Default_Benchmark_Timer; -#else - /* I have not had good success using clock(), the results seem - * pretty bogus, but as a last resort it works. - */ - typedef ANSI_Clock_Timer Default_Benchmark_Timer; -#endif - /** * Algorithm benchmark * @param name the name of the algorithm to test (cipher, hash, or MAC) @@ -50,7 +27,6 @@ namespace Botan { std::map<std::string, double> algorithm_benchmark(const std::string& name, u32bit milliseconds, - Timer& timer, RandomNumberGenerator& rng, Algorithm_Factory& af); |