pub struct TinyVm { /* private fields */ }
Expand description
The TinyVm
virtual machine state.
Implementations§
source§impl TinyVm
impl TinyVm
sourcepub fn new(code: Vec<TinyInsn>) -> Self
pub fn new(code: Vec<TinyInsn>) -> Self
Create a new TinyVm
and initialize the instruction memory from code
.
sourcepub fn interp(&mut self)
pub fn interp(&mut self)
Run in interpreter mode until the next TinyInsn::Halt
instruction is hit.
sourcepub fn jit(&mut self)
pub fn jit(&mut self)
Run in JIT mode until the next TinyInsn::Halt
instruction is hit. Translate guest
basic blocks on demand.
Auto Trait Implementations§
impl RefUnwindSafe for TinyVm
impl !Send for TinyVm
impl !Sync for TinyVm
impl Unpin for TinyVm
impl UnwindSafe for TinyVm
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