wasm-micro-runtime/language-bindings/python/wasm-c-api
Enrico Loparco 7692f32a94
Allow overriding max memory on module instantiation (#3198)
This PR adds a max_memory_pages parameter to module instantiation APIs,
to allow overriding the max memory defined in the WASM module.

Sticking to the max memory defined in the module is quite limiting when
using shared memory in production. If targeted devices have different
memory constraints, many wasm files have to be generated with different
max memory values. And device constraints may not be known in advance.

Being able to set the max memory value during module instantiation allows
to reuse the same wasm module, e.g. by retrying instantiation with different
max memory value.
2024-03-05 17:53:26 +08:00
..
docs Allow overriding max memory on module instantiation (#3198) 2024-03-05 17:53:26 +08:00
samples Add WAMR API bindings in Python (#1959) 2023-02-16 15:21:28 +08:00
tests Remove deprecated tests in language-bindings python (#3018) 2024-01-16 10:15:56 +08:00
utils Add WAMR API bindings in Python (#1959) 2023-02-16 15:21:28 +08:00
README.md Add WAMR API bindings in Python (#1959) 2023-02-16 15:21:28 +08:00
requirements.txt Add WAMR API bindings in Python (#1959) 2023-02-16 15:21:28 +08:00

WASM-C-API

Examples

There is a simple example to show how to use bindings. Actually, the python binding follows C-APIs. There it should be easy if be familiar with programming with wasm-c-api.

Unit test cases under ./tests could be another but more complete references.