Skip to main content

ExecutionReport

Struct ExecutionReport 

Source
pub(crate) struct ExecutionReport {
    pub(crate) benchmark: &'static str,
    pub(crate) backend: Backend,
    pub(crate) iterations: u32,
    pub(crate) wall_ns: Stats,
    pub(crate) fuel_spent: u64,
    pub(crate) fuel_per_sec: f64,
    pub(crate) heap_peak_bytes: Stats,
    pub(crate) host_calls: u64,
    pub(crate) irreversible_writes: u64,
    pub(crate) instructions: Option<u64>,
    pub(crate) ok: bool,
}
Expand description

One benchmark’s execution report on one backend: wall time, fuel spent, and the heap’s peak live bytes.

fuel_spent is the backend’s own normalized work counter, unaffected by machine noise and comparable only against itself: ADR 0019 says an instruction is not an AST node and there is no honest mapping between them, so the two backends’ fuel figures are two measurements and not one comparison. wall_ns is what compares them.

Fields§

§benchmark: &'static str§backend: Backend§iterations: u32§wall_ns: Stats§fuel_spent: u64§fuel_per_sec: f64§heap_peak_bytes: Stats

The largest live set a collection measured, on the backends that collect an object heap.

On vm this is a different statistic under the same name, and there is no honest way to make it the same one: that backend has no object heap to take a live set of, it has a heap region, and what it can answer is how many words of it the run held. So the vm row reports the region’s size in bytes — free blocks included — and the ast row reports what it always did. Read the vm figure against itself and not against the row above it.

§host_calls: u64§irreversible_writes: u64§instructions: Option<u64>

How many instructions the run executed, or None on the interpreter.

§ok: bool

Implementations§

Source§

impl ExecutionReport

Source

pub(crate) fn to_json(&self) -> String

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.