Skip to main content

ExecutionCollector

Struct ExecutionCollector 

Source
pub struct ExecutionCollector { /* private fields */ }
Expand description

Keeps the terminal executions grouped by outcome. Pass one to explore when you want the graphs, canonical keys or pending sends of each outcome, not just how many there were.

Under a parallel run the executions are collected in a nondeterministic order (the counts are still exact); compare canonical-key sets, not their order.

Implementations§

Source§

impl ExecutionCollector

Source

pub fn new() -> Self

Source

pub fn full(&self) -> Vec<Execution>

The full executions collected so far.

Source

pub fn blocked(&self) -> Vec<Execution>

The blocked executions (maximal consistent prefixes).

Source

pub fn errors(&self) -> Vec<Execution>

The erroneous executions.

Source

pub fn terminals(&self) -> Vec<Execution>

Full followed by blocked - the terminal executions the search must not duplicate.

Source

pub fn full_count(&self) -> usize

Source

pub fn blocked_count(&self) -> usize

Source

pub fn error_count(&self) -> usize

Source

pub fn terminal_count(&self) -> usize

Full + blocked, the terminal count.

Source

pub fn full_keys(&self) -> Vec<String>

Canonical keys of the full executions.

Source

pub fn terminal_keys(&self) -> Vec<String>

Canonical keys over full plus blocked, for the duplicate check.

Source

pub fn error_keys(&self) -> Vec<String>

Canonical keys of the erroneous executions.

Trait Implementations§

Source§

impl Debug for ExecutionCollector

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for ExecutionCollector

Source§

fn default() -> ExecutionCollector

Returns the “default value” for a type. Read more
Source§

impl Observer for ExecutionCollector

Source§

fn on_execution(&self, exec: &Execution, kind: ExecutionKind)

A terminal execution (full / blocked / error) was reached.
Source§

fn on_event_added(&self, _g: &ExecutionGraph, _e: EventId)

A fresh event e, maximal in insertion order, was added to g.
Source§

fn on_rf_choice(&self, _g: &ExecutionGraph, _r: EventId, _src: Option<EventId>)

Receive r was pointed at source src (None means no message) before a consistency check.
Source§

fn on_inconsistent(&self, _g: &ExecutionGraph)

A graph was found inconsistent and dropped.
Source§

fn on_backward_revisit( &self, _g: &ExecutionGraph, _r: EventId, _s: EventId, _deleted: &BTreeSet<EventId>, )

A backward revisit that sets rf(r) to s is about to run; deleted lists the events it removes (still including s).
Source§

fn on_revisit_rejected(&self, _g: &ExecutionGraph, _r: EventId, _s: EventId)

A candidate backward revisit setting rf(r) to s was rejected.
Source§

fn on_thread_blocked(&self, _g: &ExecutionGraph, _tid: Tid)

Thread tid is blocked on a receive with no message in g.

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> 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> 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.

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.