Struct wasmtime::InstanceLimits [−][src]
Expand description
Represents the limits placed on instances by the pooling instance allocation strategy.
Fields
count: u32
The maximum number of concurrent instances supported (default is 1000).
memory_reservation_size: u64
The maximum size, in bytes, of host address space to reserve for each linear memory of an instance.
Note: this value has important performance ramifications.
On 64-bit platforms, the default for this value will be 6 GiB. A value of less than 4 GiB will
force runtime bounds checking for memory accesses and thus will negatively impact performance.
Any value above 4 GiB will start eliding bounds checks provided the offset
of the memory access is
less than (memory_reservation_size
- 4 GiB). A value of 8 GiB will completely elide all bounds
checks; consequently, 8 GiB will be the maximum supported value. The default of 6 GiB reserves
less host address space for each instance, but a memory access with an offset above 2 GiB will incur
runtime bounds checks.
On 32-bit platforms, the default for this value will be 10 MiB. A 32-bit host has very limited address space to reserve for a lot of concurrent instances. As a result, runtime bounds checking will be used for all memory accesses. For better runtime performance, a 64-bit host is recommended.
This value will be rounded up by the WebAssembly page size (64 KiB).
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for InstanceLimits
impl Send for InstanceLimits
impl Sync for InstanceLimits
impl Unpin for InstanceLimits
impl UnwindSafe for InstanceLimits
Blanket Implementations
Mutably borrows from an owned value. Read more
type Output = T
type Output = T
Should always be Self
pub fn vzip(self) -> V