bench: say non-pruning
This commit is contained in:
parent
60b4fdd836
commit
47050a6871
@ -4,7 +4,7 @@ use othello::{
|
||||
repr::{Board, Piece},
|
||||
};
|
||||
|
||||
fn extend_layers_test(depth: usize, arena_size: usize) -> usize {
|
||||
fn extend_layers_no_pruning(depth: usize, arena_size: usize) -> usize {
|
||||
let config = FutureMoveConfig {
|
||||
max_depth: depth,
|
||||
min_arena_depth_sub: 4,
|
||||
@ -19,18 +19,15 @@ fn extend_layers_test(depth: usize, arena_size: usize) -> usize {
|
||||
}
|
||||
|
||||
fn criterion_benchmark(c: &mut Criterion) {
|
||||
let mut group = c.benchmark_group("extend_layer");
|
||||
// group.measurement_time(Duration::from_secs(10));
|
||||
// group.sample_size(1000);
|
||||
|
||||
let mut group = c.benchmark_group("extend_layer (no pruning)");
|
||||
const ARENA_SIZE: usize = 10_000_000;
|
||||
|
||||
for depth in 1..8 {
|
||||
group.throughput(Throughput::Elements(
|
||||
extend_layers_test(depth, ARENA_SIZE) as u64
|
||||
extend_layers_no_pruning(depth, ARENA_SIZE) as u64,
|
||||
));
|
||||
group.bench_with_input(BenchmarkId::from_parameter(depth), &depth, |b, depth| {
|
||||
b.iter(|| extend_layers_test(*depth, ARENA_SIZE));
|
||||
b.iter(|| extend_layers_no_pruning(*depth, ARENA_SIZE));
|
||||
});
|
||||
}
|
||||
group.finish();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user