diff options
author | Martin Ankerl <Martin.Ankerl@gmail.com> | 2017-10-17 16:48:02 +0200 |
---|---|---|
committer | Martin Ankerl <Martin.Ankerl@gmail.com> | 2017-12-23 11:03:17 +0100 |
commit | 00721e69f8280f8bc59bede43b335ecc347d4fdf (patch) | |
tree | 950b08aebdfa195a4f166664dd9934164d2edf59 /src/bench/Examples.cpp | |
parent | 604e08c83cf58ca7e7cda2ab284c1ace7bb12977 (diff) |
Improved microbenchmarking with multiple features.
* inline performance critical code
* Average runtime is specified and used to calculate iterations.
* Console: show median of multiple runs
* plot: show box plot
* filter benchmarks
* specify scaling factor
* ignore src/test and src/bench in command line check script
* number of iterations instead of time
* Replaced runtime in BENCHMARK makro number of iterations.
* Added -? to bench_bitcoin
* Benchmark plotly.js URL, width, height can be customized
* Fixed incorrect precision warning
Diffstat (limited to 'src/bench/Examples.cpp')
-rw-r--r-- | src/bench/Examples.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bench/Examples.cpp b/src/bench/Examples.cpp index 536e450940..47d80e5e01 100644 --- a/src/bench/Examples.cpp +++ b/src/bench/Examples.cpp @@ -15,7 +15,7 @@ static void Sleep100ms(benchmark::State& state) } } -BENCHMARK(Sleep100ms); +BENCHMARK(Sleep100ms, 10); // Extremely fast-running benchmark: #include <math.h> @@ -31,4 +31,4 @@ static void Trig(benchmark::State& state) } } -BENCHMARK(Trig); +BENCHMARK(Trig, 12 * 1000 * 1000); |