requireInBounds
Validates a guest-controlled window [ptr, ptr + len) against the live linear-memory size, in Long space so no operand can have sign-wrapped.
Rejects — as a WasmExecutionException, a guest runtime fault, never an OOB host-memory access or a raw non-WasmException — any window where ptr/len is negative, len cannot fit a ByteArray (len > Int.MAX_VALUE), or ptr + len exceeds memorySize.
Parameters
memorySize
the current linear-memory size in bytes, fetched after the guest call that produced the window (warp_alloc or warp_run may have grown memory).