From 2ff1d75882fedf177b2e429a4b217aa4a11b9351 Mon Sep 17 00:00:00 2001 From: Aria Shrimpton Date: Tue, 23 Jan 2024 12:56:17 +0000 Subject: benchmark fixes --- src/crates/benchmarker/src/container.rs | 12 ++++++------ src/crates/candelabra/src/cost/benchmark.rs | 3 +-- 2 files changed, 7 insertions(+), 8 deletions(-) (limited to 'src/crates') diff --git a/src/crates/benchmarker/src/container.rs b/src/crates/benchmarker/src/container.rs index f1c9948..004c639 100644 --- a/src/crates/benchmarker/src/container.rs +++ b/src/crates/benchmarker/src/container.rs @@ -1,11 +1,11 @@ -use primrose_library::traits::{Container, Indexable}; +use primrose_library::traits::Container; use rand::{distributions::Standard, prelude::Distribution, random, thread_rng, Rng}; use crate::{benchmark_op, print_result}; pub fn benchmark_container(ns: &[usize]) where - T: Container + Indexable + Default + Clone, + T: Container + Default + Clone, E: Copy, Standard: Distribution, { @@ -19,7 +19,7 @@ where fn scenario_populate(n: usize) where - T: Container + Indexable + Default + Clone, + T: Container + Default + Clone, E: Copy, Standard: Distribution, { @@ -42,7 +42,7 @@ where fn scenario_contains(n: usize) where - T: Container + Indexable + Default + Clone, + T: Container + Default + Clone, E: Copy, Standard: Distribution, { @@ -76,7 +76,7 @@ where fn scenario_remove(n: usize) where - T: Container + Indexable + Default + Clone, + T: Container + Default + Clone, E: Copy, Standard: Distribution, { @@ -110,7 +110,7 @@ where fn scenario_clear(n: usize) where - T: Container + Indexable + Default + Clone, + T: Container + Default + Clone, E: Copy, Standard: Distribution, { diff --git a/src/crates/candelabra/src/cost/benchmark.rs b/src/crates/candelabra/src/cost/benchmark.rs index bafe9bd..48c7a84 100644 --- a/src/crates/candelabra/src/cost/benchmark.rs +++ b/src/crates/candelabra/src/cost/benchmark.rs @@ -25,8 +25,7 @@ pub const ELEM_TYPE: &str = "usize"; /// String representation of the array of N values we use for benchmarking pub const NS: &str = "[ - 64, 128, 256, 512, 1024, 2048, 3072, 4096, 5120, 6144, 7168, 8192, 16384, 24576, 32768, - 40960, 49152, 57344, 65536, + 64, 128, 256, 512, 2048, 5120, 16384, 32768, 65536, ]"; /// Results for a whole suite of benchmarks -- cgit v1.2.3