pub struct RuntimeConfig {
pub wasm_threads: bool,
pub wasm_simd: bool,
pub wasm_reference_types: bool,
pub max_memory_pages: u32,
pub fuel_limit: u64,
}Expand description
WASM runtime configuration
Fields§
§wasm_threads: boolEnable threading support (for SharedArrayBuffer)
wasm_simd: boolEnable SIMD support
wasm_reference_types: boolEnable reference types
max_memory_pages: u32Maximum memory pages (64KB each)
fuel_limit: u64Fuel limit for execution (0 = unlimited)
Implementations§
Source§impl RuntimeConfig
impl RuntimeConfig
Sourcepub const fn with_threads(self, enabled: bool) -> Self
pub const fn with_threads(self, enabled: bool) -> Self
Enable threading support
Sourcepub const fn with_fuel_limit(self, limit: u64) -> Self
pub const fn with_fuel_limit(self, limit: u64) -> Self
Set fuel limit
Trait Implementations§
Source§impl Clone for RuntimeConfig
impl Clone for RuntimeConfig
Source§fn clone(&self) -> RuntimeConfig
fn clone(&self) -> RuntimeConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RuntimeConfig
impl Debug for RuntimeConfig
Source§impl Default for RuntimeConfig
impl Default for RuntimeConfig
impl Copy for RuntimeConfig
Auto Trait Implementations§
impl Freeze for RuntimeConfig
impl RefUnwindSafe for RuntimeConfig
impl Send for RuntimeConfig
impl Sync for RuntimeConfig
impl Unpin for RuntimeConfig
impl UnsafeUnpin for RuntimeConfig
impl UnwindSafe for RuntimeConfig
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