Struct wasmtime_runtime::VMRuntimeLimits
source · #[repr(C)]pub struct VMRuntimeLimits {
pub stack_limit: UnsafeCell<usize>,
pub fuel_consumed: UnsafeCell<i64>,
pub epoch_deadline: UnsafeCell<u64>,
}
Expand description
Structure used to control interrupting wasm code.
Fields§
§stack_limit: UnsafeCell<usize>
Current stack limit of the wasm module.
For more information see crates/cranelift/src/lib.rs
.
fuel_consumed: UnsafeCell<i64>
Indicator of how much fuel has been consumed and is remaining to WebAssembly.
This field is typically negative and increments towards positive. Upon turning positive a wasm trap will be generated. This field is only modified if wasm is configured to consume fuel.
epoch_deadline: UnsafeCell<u64>
Deadline epoch for interruption: if epoch-based interruption is enabled and the global (per engine) epoch counter is observed to reach or exceed this value, the guest code will yield if running asynchronously.
Trait Implementations§
source§impl Debug for VMRuntimeLimits
impl Debug for VMRuntimeLimits
source§impl Default for VMRuntimeLimits
impl Default for VMRuntimeLimits
source§fn default() -> VMRuntimeLimits
fn default() -> VMRuntimeLimits
Returns the “default value” for a type. Read more