Run benchmark matrix.
(crit: &mut Criterion, matrix: &BenchmarkMatrix)
| 179 | |
| 180 | /// Run benchmark matrix. |
| 181 | pub fn run_benchmark_matrix(crit: &mut Criterion, matrix: &BenchmarkMatrix) { |
| 182 | let configs = matrix.generate_configs(); |
| 183 | |
| 184 | // Group configs by seed level to avoid duplicate seeding |
| 185 | let mut by_seed_level = std::collections::HashMap::new(); |
| 186 | for config in configs { |
| 187 | by_seed_level |
| 188 | .entry(config.seed) |
| 189 | .or_insert_with(Vec::new) |
| 190 | .push(config); |
| 191 | } |
| 192 | |
| 193 | for (seed_level, seed_configs) in by_seed_level { |
| 194 | eprintln!( |
| 195 | "Setting up seed level: {:?} for {} configurations", |
| 196 | seed_level, |
| 197 | seed_configs.len() |
| 198 | ); |
| 199 | run_benchmark_seed_group(crit, seed_level, seed_configs); |
| 200 | } |
| 201 | } |
| 202 | |
| 203 | /// Run all benchmark configs for a single seed level (shared seeding). |
| 204 | fn run_benchmark_seed_group( |
no test coverage detected