Struct wasmtime_runtime::VMExternRefActivationsTable [−][src]
#[repr(C)]pub struct VMExternRefActivationsTable { /* fields omitted */ }
Expand description
A table that over-approximizes the set of VMExternRefs that any Wasm
activation on this thread is currently using.
Under the covers, this is a simple bump allocator that allows duplicate entries. Deduplication happens at GC time.
Implementations
impl VMExternRefActivationsTable[src]
impl VMExternRefActivationsTable[src]pub fn try_insert(&self, externref: VMExternRef) -> Result<(), VMExternRef>[src]
pub fn try_insert(&self, externref: VMExternRef) -> Result<(), VMExternRef>[src]Try and insert a VMExternRef into this table.
This is a fast path that only succeeds when the bump chunk has the capacity for the requested insertion.
If the insertion fails, then the VMExternRef is given back. Callers
may attempt a GC to free up space and try again, or may call
insert_slow_path to infallibly insert the reference (potentially
allocating additional space in the table to hold it).
pub unsafe fn insert_with_gc(
    &self, 
    externref: VMExternRef, 
    stack_maps_registry: &StackMapRegistry
)[src]
pub unsafe fn insert_with_gc(
    &self, 
    externref: VMExternRef, 
    stack_maps_registry: &StackMapRegistry
)[src]Insert a reference into the table, falling back on a GC to clear up space if the table is already full.
Unsafety
The same as gc.
pub fn stack_canary(&self) -> Option<usize>[src]
pub fn stack_canary(&self) -> Option<usize>[src]Fetches the current value of this table’s stack canary.
This should only be used in conjunction with setting the stack canary
below if the return value is None typically. This is called from RAII
guards in wasmtime::func::invoke_wasm_and_catch_traps.
For more information on canaries see the gc functions below.
pub fn set_stack_canary(&self, canary: Option<usize>)[src]
pub fn set_stack_canary(&self, canary: Option<usize>)[src]Sets the current value of the stack canary.
This is called from RAII guards in
wasmtime::func::invoke_wasm_and_catch_traps. This is used to update
the stack canary to a concrete value and then reset it back to None
when wasm is finished.
For more information on canaries see the gc functions below.
Auto Trait Implementations
impl !RefUnwindSafe for VMExternRefActivationsTable
impl !Send for VMExternRefActivationsTable
impl !Sync for VMExternRefActivationsTable
impl Unpin for VMExternRefActivationsTable
impl !UnwindSafe for VMExternRefActivationsTable
Blanket Implementations
impl<T> BorrowMut<T> for T where
    T: ?Sized, [src]
impl<T> BorrowMut<T> for T where
    T: ?Sized, [src]pub fn borrow_mut(&mut self) -> &mut T[src]
pub fn borrow_mut(&mut self) -> &mut T[src]Mutably borrows from an owned value. Read more
impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
impl<V, T> VZip<V> for T where
    V: MultiLane<T>,