Stream: wasmtime

Topic: Memory limits in C API


view this post on Zulip Lukas (Feb 10 2023 at 10:56):

Hi, I was wondering, how do I use resource/memory limits that were introduced in this PR https://github.com/bytecodealliance/wasmtime/pull/2736 more specifically StoreLimits.memory_growing https://docs.wasmtime.dev/api/wasmtime/struct.StoreLimits.html#method.memory_growing in C API? Even though the C API contains Fuel APIs https://github.com/bytecodealliance/wasmtime/blob/main/crates/c-api/src/store.rs#L134 it does not contain limits for the memory, or does it?

This PR adds a ResourceLimiter trait to the Wasmtime API. When used in conjunction with Store::new_with_limiter, this can be used to monitor and prevent WebAssembly code from growing linear memorie...
A fast and secure runtime for WebAssembly. Contribute to bytecodealliance/wasmtime development by creating an account on GitHub.

Last updated: Oct 23 2024 at 20:03 UTC