pub struct Machine { /* private fields */ }Expand description
A synchronous interpreter for one function of a validated Program.
Implementations§
Source§impl Machine
impl Machine
Sourcepub fn run_instrumented<P: VmProbe>(&mut self, probe: &mut P) -> VmOutcome
pub fn run_instrumented<P: VmProbe>(&mut self, probe: &mut P) -> VmOutcome
Runs through the same production dispatch implementation while emitting compact scalar events. This path deliberately does not execute tracing JIT recordings; JIT internals have a separate telemetry contract.
Sourcepub fn resume_instrumented<P: VmProbe>(
&mut self,
state: PromiseState,
probe: &mut P,
) -> VmOutcome
pub fn resume_instrumented<P: VmProbe>( &mut self, state: PromiseState, probe: &mut P, ) -> VmOutcome
Applies one settlement to a machine stopped at Await, emits the
resume or unwind boundary, and continues through run_instrumented.
Source§impl Machine
impl Machine
Sourcepub fn step_instrumented_boundary<P: VmProbe>(
&mut self,
probe: &mut P,
) -> VmBoundary
pub fn step_instrumented_boundary<P: VmProbe>( &mut self, probe: &mut P, ) -> VmBoundary
Executes exactly one production dispatch boundary without projecting VM state. The caller may lazily inspect the machine after event/filter matching through the shared instrumentation hub.
Sourcepub fn resume_instrumented_boundary<P: VmProbe>(
&mut self,
state: PromiseState,
probe: &mut P,
) -> VmBoundary
pub fn resume_instrumented_boundary<P: VmProbe>( &mut self, state: PromiseState, probe: &mut P, ) -> VmBoundary
Applies exactly one settlement at the actual retained Await boundary.
Subsequent instructions are left for later step_instrumented_boundary
calls.
Source§impl Machine
impl Machine
Source§impl Machine
impl Machine
Sourcepub fn resume(&mut self, state: PromiseState) -> VmOutcome
pub fn resume(&mut self, state: PromiseState) -> VmOutcome
Continues a machine stopped at Await. The settlement is applied at
the suspended instruction so ordinary exception handlers see a
rejected promise exactly like a guest throw.
pub fn resume_yield(&mut self, value: Value) -> VmOutcome
Auto Trait Implementations§
impl !RefUnwindSafe for Machine
impl !Send for Machine
impl !Sync for Machine
impl !UnwindSafe for Machine
impl Freeze for Machine
impl Unpin for Machine
impl UnsafeUnpin for Machine
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> ⓘ
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> ⓘ
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