#[non_exhaustive]pub struct BenchmarkSettings {
pub setup: RunSetup,
pub steps: u64,
pub warmup: u64,
pub global_warmup: u64,
pub repetitions: u64,
}Available on non-WebAssembly only.
Expand description
Model, setup and lengths of one benchmark.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.setup: RunSetupValues, base seed and scheduled actions of every repetition.
steps: u64Timed steps per repetition.
warmup: u64Untimed steps before each repetition’s timed ones, on that repetition’s own state.
Note that a GPU repetition with no warm-up times wgpu’s zero-fill of every buffer its build left unseeded, which runs in the first submission that touches the buffer. A warm-up of one step keeps it out of the timed steps.
global_warmup: u64Untimed steps of one throwaway state before the first repetition, to bring the hardware off its idle clocks.
repetitions: u64Number of timed repetitions, each on a freshly built state.
Implementations§
Trait Implementations§
Source§impl Clone for BenchmarkSettings
impl Clone for BenchmarkSettings
Auto Trait Implementations§
impl !RefUnwindSafe for BenchmarkSettings
impl !UnwindSafe for BenchmarkSettings
impl Freeze for BenchmarkSettings
impl Send for BenchmarkSettings
impl Sync for BenchmarkSettings
impl Unpin for BenchmarkSettings
impl UnsafeUnpin for BenchmarkSettings
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more