Stream: git-wasmtime

Topic: wasmtime / PR #6776 Update preview1 to trap on misaligned...


view this post on Zulip Wasmtime GitHub notifications bot (Jul 26 2023 at 15:16):

alexcrichton opened PR #6776 from alexcrichton:trap-on-misalignment to bytecodealliance:main:

Previously Wasmtime would return EINVAL to a guest but the upstream documentation indicates that misaligned pointers should trap, so this commit updates the alignment error to get converted into a trap rather than than being returned to the guest.

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

view this post on Zulip Wasmtime GitHub notifications bot (Jul 26 2023 at 15:16):

alexcrichton requested wasmtime-core-reviewers for a review on PR #6776.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 26 2023 at 15:16):

alexcrichton requested pchickey for a review on PR #6776.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 28 2023 at 17:25):

pchickey submitted PR review:

I merged the pointer out of bounds changes upstream, so you can also change the PtrOutOfBounds and PtrOverflow cases to trap.

The new preview 1 implementation inside wasi/src/preview2/preview1 should also be updated as well. Unfortunately, it looks like instead of using a From<GuestError> impl there, it instead uses a pattern of Result<_, GuestError>::or(Err(Errno::Inval)) at each call site, so that is a tougher job. Its OK to not take that on as part of this PR, but we should file an issue on it if you want to defer it.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 02 2023 at 09:47):

alexcrichton updated PR #6776.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 02 2023 at 10:04):

alexcrichton updated PR #6776.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 02 2023 at 10:09):

alexcrichton updated PR #6776.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 02 2023 at 22:15):

pchickey submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 02 2023 at 22:57):

pchickey merged PR #6776.


Last updated: Oct 23 2024 at 20:03 UTC