Stream: git-wasmtime

Topic: wasmtime / PR #5921 cranelift-interpreter: Add trap on mi...


view this post on Zulip Wasmtime GitHub notifications bot (Mar 03 2023 at 14:39):

jan-justin opened PR #5921 from cranelift-interpreter-trap-misaligned to main:

This PR adds trap generation on misaligned memory accesses when the aligned memory flag is set, as proposed over at #5899.

<!--

Please ensure that the following steps are all taken care of before submitting
the PR.

Please ensure all communication adheres to the code of conduct.
-->

view this post on Zulip Wasmtime GitHub notifications bot (Mar 04 2023 at 13:29):

afonso360 submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 04 2023 at 13:29):

afonso360 submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 04 2023 at 13:29):

afonso360 created PR review comment:

Me and @jan-justin were discussing this on Zulip, and we were unsure if unaligned stack_{load,store}s allowed. By coincidence the fuzzer found a similar issue in #5922 so we will probably get our answer there!

view this post on Zulip Wasmtime GitHub notifications bot (Mar 04 2023 at 13:29):

afonso360 created PR review comment:

Can we change this to be explicit_slot 16? The reason is that this store is accessing memory out of bounds, and the interpreter didn't catch it!

Technically the stack slots can be reordered, so we could reorder this slot to be at the end, and then we would access past the end of the stack. The interpreter never does that so it would never detect that case.

I've opened #5927 to track this!

view this post on Zulip Wasmtime GitHub notifications bot (Mar 04 2023 at 13:31):

afonso360 edited PR review comment.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 05 2023 at 10:47):

jan-justin updated PR #5921 from cranelift-interpreter-trap-misaligned to main.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 07 2023 at 00:06):

jameysharp submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 07 2023 at 00:45):

jameysharp merged PR #5921.


Last updated: Nov 22 2024 at 16:03 UTC