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
<<HelpMessageOpt("-?",_("Print this help message and exit"))
<<HelpMessageOpt("-list",_("List benchmarks without executing them. Can be combined with -scaling and -filter"))
<<HelpMessageOpt("-evals=<n>",strprintf(_("Number of measurement evaluations to perform. (default: %u)"),DEFAULT_BENCH_EVALUATIONS))
<<HelpMessageOpt("-filter=<regex>",strprintf(_("Regular expression filter to select benchmark by name (default: %s)"),DEFAULT_BENCH_FILTER))
<<HelpMessageOpt("-scaling=<n>",strprintf(_("Scaling factor for benchmark's runtime (default: %u)"),DEFAULT_BENCH_SCALING))
<<HelpMessageOpt("-printer=(console|plot)",strprintf(_("Choose printer format. console: print data to console. plot: Print results as HTML graph (default: %s)"),DEFAULT_BENCH_PRINTER))
<<HelpMessageOpt("-plot-plotlyurl=<uri>",strprintf(_("URL to use for plotly.js (default: %s)"),DEFAULT_PLOT_PLOTLYURL))
<<HelpMessageOpt("-plot-width=<x>",strprintf(_("Plot width in pixel (default: %u)"),DEFAULT_PLOT_WIDTH))
<<HelpMessageOpt("-plot-height=<x>",strprintf(_("Plot height in pixel (default: %u)"),DEFAULT_PLOT_HEIGHT));
return0;
}
SHA256AutoDetect();
RandomInit();
ECC_Start();
SetupEnvironment();
fPrintToDebugLog=false;// don't want to write to debug.log file