2 ms·
Any embedded platform without MMU would have that same problem though. Programming languages and their runtimes should not depend on such hardware features IMH
by flohofwoe 3y ago
Any embedded platform without MMU would have that same problem though.
Programming languages and their runtimes should not depend on such hardware features IMHO (at most use them optionally for performance optimization).
Also, my guess is that WASM engines outside the browser would absolutely be able to trap on "zero page" accesses.
AFAIK the limitation of address zero being a regular memory location when running WASM in browsers is just a side effect of the WASM heap being a regular Javascript ArrayBuffer object, which cannot start at an index greater than zero (and adding an offset for every heap access would be prohibitively expensive). A WASM runtime which doesn't require to interoperate with Javascript could map the WASM heap to regular virtual memory with the first page being read/write protected.