Struct puffin::fuzzer::stats_monitor::StatsMonitor

source ·
pub struct StatsMonitor {
    monitor: Box<dyn ClonableMonitor>,
    handlers: Vec<Box<dyn EventHandler>>,
}
Expand description

Tracking stats during fuzzing and display both per-client and cumulative info.

Fields§

§monitor: Box<dyn ClonableMonitor>§handlers: Vec<Box<dyn EventHandler>>

Implementations§

source§

impl StatsMonitor

source

pub fn with_tui_output(stats_file: PathBuf) -> Self

source

pub fn with_raw_output(stats_file: PathBuf) -> Self

source

fn new( monitor: Box<dyn ClonableMonitor>, handlers: Vec<Box<dyn EventHandler>>, ) -> Self

source

fn client(&mut self, id: ClientId) -> Statistics

source

fn global(&mut self) -> Statistics

source

fn dispatch(&mut self, sender: ClientId, msg: &str, stats: &Statistics)

Trait Implementations§

source§

impl Clone for StatsMonitor

source§

fn clone(&self) -> StatsMonitor

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Monitor for StatsMonitor

source§

fn client_stats_mut(&mut self) -> &mut Vec<ClientStats>

The client monitor (mutable)
source§

fn client_stats(&self) -> &[ClientStats]

The client monitor
source§

fn start_time(&self) -> Duration

Creation time
source§

fn set_start_time(&mut self, time: Duration)

Set creation time
source§

fn display(&mut self, event_msg: String, sender_id: ClientId)

Show the monitor to the user
§

fn corpus_size(&self) -> u64

Amount of elements in the corpus (combined for all children)
§

fn objective_size(&self) -> u64

Amount of elements in the objectives (combined for all children)
§

fn total_execs(&self) -> u64

Total executions
§

fn execs_per_sec(&mut self) -> f64

Executions per second
§

fn execs_per_sec_pretty(&mut self) -> String

Executions per second
§

fn client_stats_insert(&mut self, client_id: ClientId)

The client monitor for a specific id, creating new if it doesn’t exist
§

fn client_stats_mut_for(&mut self, client_id: ClientId) -> &mut ClientStats

Get mutable reference to client stats
§

fn client_stats_for(&self, client_id: ClientId) -> &ClientStats

Get immutable reference to client stats
§

fn aggregate(&mut self, _name: &str)

Aggregate the results in case there’re multiple clients

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> AsAny for T
where T: 'static,

source§

fn as_any(&self) -> &(dyn Any + 'static)

source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> DynClone for T
where T: Clone,

source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<Tail, T> Prepend<T> for Tail

§

type PreprendResult = Tail

The Resulting [TupleList], of an [Prepend::prepend()] call, including the prepended entry.
§

fn prepend(self, value: T) -> (T, <Tail as Prepend<T>>::PreprendResult)

Prepend a value to this tuple, returning a new tuple with prepended value.
source§

impl<T> ToOwned for T
where T: Clone,

source§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> MaybeHasScalabilityMonitor for T

§

impl<T> UnsafeAny for T
where T: Any,