Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(425)

Unified Diff: third_party/google_benchmark/src/benchmark_api_internal.h

Issue 2865663003: Adding Google benchmarking library. (Closed)
Patch Set: Sketch. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/google_benchmark/src/benchmark_api_internal.h
diff --git a/third_party/google_benchmark/src/benchmark_api_internal.h b/third_party/google_benchmark/src/benchmark_api_internal.h
new file mode 100644
index 0000000000000000000000000000000000000000..c2208737c3722f810ff5a92c81d140d92f2b2bf4
--- /dev/null
+++ b/third_party/google_benchmark/src/benchmark_api_internal.h
@@ -0,0 +1,46 @@
+#ifndef BENCHMARK_API_INTERNAL_H
+#define BENCHMARK_API_INTERNAL_H
+
+#include "benchmark/benchmark_api.h"
+
+#include <cmath>
+#include <iosfwd>
+#include <limits>
+#include <string>
+#include <vector>
+
+namespace benchmark {
+namespace internal {
+
+// Information kept per benchmark we may want to run
+struct Benchmark::Instance {
+ std::string name;
+ Benchmark* benchmark;
+ ReportMode report_mode;
+ std::vector<int> arg;
+ TimeUnit time_unit;
+ int range_multiplier;
+ bool use_real_time;
+ bool use_manual_time;
+ BigO complexity;
+ BigOFunc* complexity_lambda;
+ UserCounters counters;
+ bool last_benchmark_instance;
+ int repetitions;
+ double min_time;
+ size_t iterations;
+ int threads; // Number of concurrent threads to us
+};
+
+bool FindBenchmarksInternal(const std::string& re,
+ std::vector<Benchmark::Instance>* benchmarks,
+ std::ostream* Err);
+
+bool IsZero(double n);
+
+ConsoleReporter::OutputOptions GetOutputOptions(bool force_no_color = false);
+
+} // end namespace internal
+} // end namespace benchmark
+
+#endif // BENCHMARK_API_INTERNAL_H
« no previous file with comments | « third_party/google_benchmark/src/benchmark.cc ('k') | third_party/google_benchmark/src/benchmark_register.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698