bench changes

This commit is contained in:
Simon Gardling 2025-02-27 12:02:53 -05:00
parent fae4aaab6f
commit a68e2e093b
Signed by: titaniumtown
GPG Key ID: 9AB28AC10ECE533D

View File

@ -19,12 +19,11 @@ fn extend_layers_test(depth: usize) {
} }
fn criterion_benchmark(c: &mut Criterion) { fn criterion_benchmark(c: &mut Criterion) {
const EXPIRE: usize = 4; let mut group = c.benchmark_group("extend_layer");
let mut group = c.benchmark_group(format!("extend_layers (expire {})", EXPIRE));
group.measurement_time(Duration::from_secs(10)); group.measurement_time(Duration::from_secs(10));
group.sample_size(1000); group.sample_size(1000);
for depth in 4..8 { for depth in 1..8 {
// TODO! maybe somehow get throughput from `extend_layers`? // TODO! maybe somehow get throughput from `extend_layers`?
// group.throughput(Throughput::Elements(depth as u64)); // group.throughput(Throughput::Elements(depth as u64));
group.bench_with_input(BenchmarkId::from_parameter(depth), &depth, |b, depth| { group.bench_with_input(BenchmarkId::from_parameter(depth), &depth, |b, depth| {