Not sure why. They could just guarantee the allocator never hands out invalid addresses no? If you’re trying to access outside the valid range that’s an out of bounds access because the memory range isn’t mapped. I’m sure I’m missing some nuance though.
The allocator never hands out invalid addresses, but the wasm code can then try to access out of the bounds of the allocated memory (eg huge array index).
The wasm runtime and other browser code runs in the same address space but must stay out of reach of the wasm code.