1 #include "benchmark/benchmark.h"
11 while (
state.KeepRunning()) {
16 std::chrono::milliseconds sleep_duration(
state.range(0));
17 while (
state.KeepRunning()) {
18 std::this_thread::sleep_for(
19 std::chrono::duration_cast<std::chrono::nanoseconds>(sleep_duration));
40 for (
int i = 0;
i < 10; ++
i) {
50 static bool invoked_before =
false;
51 assert(!invoked_before);
52 invoked_before =
true;
56 size_t actual_iterations = 0;