Baseline
| 40 | |
| 41 | // Baseline |
| 42 | void for_loop(benchmark::State& state) { |
| 43 | auto source = generate_junk(kSize); |
| 44 | std::vector<int> target(kSize); |
| 45 | |
| 46 | for (auto _ : state) { |
| 47 | for (int64_t index = 0; index < kSize; ++index) target[index] = source[index] + 1; |
| 48 | } |
| 49 | state.SetItemsProcessed(state.iterations() * kSize); |
| 50 | } |
| 51 | |
| 52 | BENCHMARK(for_loop); |
| 53 |
nothing calls this directly
no test coverage detected