| 141 | } |
| 142 | |
| 143 | void ReadFileMetadata(benchmark::State& state) { |
| 144 | MetadataBenchmark benchmark(&state); |
| 145 | auto contents = benchmark.WriteFile(&state); |
| 146 | |
| 147 | for (auto _ : state) { |
| 148 | benchmark.ReadFile(contents); |
| 149 | } |
| 150 | state.SetItemsProcessed(state.iterations()); |
| 151 | } |
| 152 | |
| 153 | BENCHMARK(WriteFileMetadataAndData)->Apply(WriteMetadataSetArgs); |
| 154 | BENCHMARK(ReadFileMetadata)->Apply(ReadMetadataSetArgs); |