pub struct BenchmarkDiff {
pub benchmark_name: String,
pub baseline: BenchmarkResult,
pub current: BenchmarkResult,
pub analysis: PerformanceChange,
}Expand description
Represents a diff between two benchmark results
Fields§
§benchmark_name: StringName of the benchmark being compared
baseline: BenchmarkResultBaseline (old) result
current: BenchmarkResultCurrent (new) result
analysis: PerformanceChangePerformance change analysis
Implementations§
Source§impl BenchmarkDiff
impl BenchmarkDiff
Sourcepub fn new(
benchmark_name: &str,
baseline: BenchmarkResult,
current: BenchmarkResult,
) -> Self
pub fn new( benchmark_name: &str, baseline: BenchmarkResult, current: BenchmarkResult, ) -> Self
Create a new benchmark diff
Sourcepub fn to_diff_format(&self) -> String
pub fn to_diff_format(&self) -> String
Generate a git-style diff output
Sourcepub fn to_summary(&self) -> String
pub fn to_summary(&self) -> String
Generate a concise diff summary
Sourcepub fn is_significant(&self) -> bool
pub fn is_significant(&self) -> bool
Check if this represents a significant change
Sourcepub fn is_regression(&self) -> bool
pub fn is_regression(&self) -> bool
Check if this represents a regression
Sourcepub fn is_improvement(&self) -> bool
pub fn is_improvement(&self) -> bool
Check if this represents an improvement
Trait Implementations§
Source§impl Clone for BenchmarkDiff
impl Clone for BenchmarkDiff
Auto Trait Implementations§
impl Freeze for BenchmarkDiff
impl RefUnwindSafe for BenchmarkDiff
impl Send for BenchmarkDiff
impl Sync for BenchmarkDiff
impl Unpin for BenchmarkDiff
impl UnsafeUnpin for BenchmarkDiff
impl UnwindSafe for BenchmarkDiff
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