pub enum Threshold {
RegressionPct(f64),
RegressionAbsoluteNs(u128),
}Expand description
A threshold defining how much slower-than-baseline is acceptable.
Variants§
RegressionPct(f64)
Fail if the new measurement is more than pct percent slower
than the baseline.
RegressionAbsoluteNs(u128)
Fail if the new measurement is more than nanos slower than
the baseline.
Implementations§
Source§impl Threshold
impl Threshold
Sourcepub fn regression_pct(pct: f64) -> Self
pub fn regression_pct(pct: f64) -> Self
Build a percent-based regression threshold.
Sourcepub fn regression_abs_ns(nanos: u128) -> Self
pub fn regression_abs_ns(nanos: u128) -> Self
Build an absolute regression threshold in nanoseconds.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Threshold
impl RefUnwindSafe for Threshold
impl Send for Threshold
impl Sync for Threshold
impl Unpin for Threshold
impl UnsafeUnpin for Threshold
impl UnwindSafe for Threshold
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