pub struct BenchmarkConfig {
pub warmup_iterations: usize,
pub measurement_iterations: usize,
pub regression_threshold_percent: f64,
pub improvement_threshold_percent: f64,
pub min_time_ns: u64,
pub save_distribution: bool,
}Expand description
Configuration for performance benchmarks
Fields§
§warmup_iterations: usizeNumber of warmup iterations
measurement_iterations: usizeNumber of measurement iterations
regression_threshold_percent: f64Regression threshold (as percentage, e.g., 10.0 means 10% slower is a regression)
improvement_threshold_percent: f64Improvement threshold (as percentage)
min_time_ns: u64Minimum execution time to consider (filter out noise)
save_distribution: boolWhether to save detailed timing distributions
Implementations§
Source§impl BenchmarkConfig
impl BenchmarkConfig
Sourcepub fn with_warmup(self, iterations: usize) -> Self
pub fn with_warmup(self, iterations: usize) -> Self
Set warmup iterations
Sourcepub fn with_measurements(self, iterations: usize) -> Self
pub fn with_measurements(self, iterations: usize) -> Self
Set measurement iterations
Sourcepub fn with_regression_threshold(self, percent: f64) -> Self
pub fn with_regression_threshold(self, percent: f64) -> Self
Set regression threshold
Trait Implementations§
Source§impl Clone for BenchmarkConfig
impl Clone for BenchmarkConfig
Source§fn clone(&self) -> BenchmarkConfig
fn clone(&self) -> BenchmarkConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BenchmarkConfig
impl Debug for BenchmarkConfig
Auto Trait Implementations§
impl Freeze for BenchmarkConfig
impl RefUnwindSafe for BenchmarkConfig
impl Send for BenchmarkConfig
impl Sync for BenchmarkConfig
impl Unpin for BenchmarkConfig
impl UnwindSafe for BenchmarkConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more