You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
wasip2: Fix/optimize read/write family of syscalls (WebAssembly#670)
This commit contains a number of fixes to `{p,}{read,write}{,v}`
functions, notably:
* For `write`-style functions the buffer passed in need not be copied to
a heap allocation. Instead it can be used as-is in-place.
* `for `*v`-style functions it's not valid to perform operations in a
loop. The functions are documented as having atomic semantics (e.g.
`writev` writes everything as one "chunk") which means that the
one-write-behavior of the adapter is required.
* `preadv` no longer leaks memory for >1 buffer passed in.
* `pwritev` is implemented in terms of `pwrite` to reduce duplication.
* `writev` only performs one write instead of performing multiple and
not handling errors in the middle.
* For `read`-style functions the return value of `memcpy` need not be
checked as the function is infallible.
* The `write` function uses the return value from `check-write` to
determine the length of the write instead of discarding it.
* The download of a precompiled wasmtime was updated to support macOS as
well.
0 commit comments