I’m new here and just started using WASM runtime.
I wrote a program to compare the memory usage of the same wasm file when running it with Wasmtime and WAMR. My understanding is that WAMR is designed to be lightweight, so it should, in theory, use less memory than Wasmtime. However, in my actual tests, we observed that Wasmtime consumed less memory than WAMR.
Below, I will describe my testing process. If there are any issues or improvements you can suggest, please let me know.
Hardware: Raspi 4 board
OS: ubuntu 22.04.5
For detailed compilation and execution steps, please refer to https://github.com/Barry-Xu-2018/wasm_runtime_evaluation/blob/main/README.md.
When the WASM program is running (during the 30-second wait in the WASM program), use the ps command to get the program's RSS (the actual physical memory used).
Teset result:
wasmtime (6.9M) < warm (10.5M)
I’m new here and just started using WASM runtime.
I wrote a program to compare the memory usage of the same wasm file when running it with Wasmtime and WAMR. My understanding is that WAMR is designed to be lightweight, so it should, in theory, use less memory than Wasmtime. However, in my actual tests, we observed that Wasmtime consumed less memory than WAMR.
Below, I will describe my testing process. If there are any issues or improvements you can suggest, please let me know.
Hardware: Raspi 4 board
OS: ubuntu 22.04.5
https://github.com/Barry-Xu-2018/wasm_runtime_evaluation/tree/main/benchmark_wasm
It executes 100 iterations of base64 encoding and decoding operations and then wait 30 seconds.
Use
wasi-sdk-32.0-arm64-linuxto product wasm imagehttps://github.com/Barry-Xu-2018/wasm_runtime_evaluation/blob/main/wasmtime_test/src/wasmtime_aot_runner.c
make wasm aot image by
wasmtime compileThe build command for wamr is
For detailed compilation and execution steps, please refer to https://github.com/Barry-Xu-2018/wasm_runtime_evaluation/blob/main/README.md.
When the WASM program is running (during the 30-second wait in the WASM program), use the
pscommand to get the program's RSS (the actual physical memory used).Teset result:
wasmtime (6.9M) < warm (10.5M)