3 ms·
> Allow Wasm to better target resource-constrained embedded environments, including those with less than 64 KiB memory available. If it has less than 64 kB of
by IshKebab 1y ago
> Allow Wasm to better target resource-constrained embedded environments, including those with less than 64 KiB memory available.
If it has less than 64 kB of memory how is it going to run a WASM runtime anyway?
And even cheap microcontrollers tend to have more than 64 kB of memory these days. Doesn't not seem remotely worth the complexity.
- titzer 1y ago> If it has less than 64 kB of memory how is it going to run a WASM runtime anyway? There is WARDuino (https://github.com/TOPLLab/WARDuino https://github.com/TOPLLab/WARDuino and https://dl.acm.org/doi/10.1145/3357390.3361029 https://dl.acm.org/doi/10.1145/3357390.3361029). A runtime that accepts Wasm modules that use a large fraction of the functionality, there is going to be a RAM requirement in the few KiB to few tens of KiB. There seems to be a branch or fork of Wasm3 for Arduino (https://github.com/wasm3/wasm3-arduino https://github.com/wasm3/wasm3-arduino). If you are willing to do, e.g. Wasm -> AVR AOT compilation, then the runtime can be quite small. That basically implies that compilation does not happen on device, but at deployment time.
- Ductapemaster 1y agoIt's not about the whole microcontroller having less than 64kB of memory - it's that each WASM module has a minimum memory size of 64kB, regardless of how much it actually requires. Also, if you need 65kB of memory, you now have to reserve 2 pages, meaning your app now needs 128kB of memory! We're working on WASM for embedded over at atym.io if you're interested.