alexcrichton opened PR #11147 from alexcrichton:jettison-unaligned-memory to bytecodealliance:main:
This commit removes the configuration knob used during fuzzing to use a custom host memory which is always unaligned on the host. The original intention for this was to help catch issues related to alignment in the x64 backend about, for example, performing unaligned SSE loads correctly (as opposed to accidentally faulting on unaligned addresses).
As shown in the test failures of #11142, however, this is technically UB for other parts of Wasmtime that assume the heap addresses are always aligned. For example Wasmtime will create safe references in to a GC heap and GC heaps are also allocated with this same allocator, meaning that Rust-safe references are unaligned (which is UB).
In practice I'm not aware of any actual issues this configuration option has ever discovered, and we've otherwise discovered alignment issues via normal fuzzing as well. Given that I think it's best to just jettison this entirely and stop trying to support it and/or tweak configuration to only use it when supported or similar.
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
alexcrichton requested fitzgen for a review on PR #11147.
alexcrichton requested wasmtime-fuzz-reviewers for a review on PR #11147.
fitzgen submitted PR review:
Yep, makes total sense.
fitzgen merged PR #11147.
Last updated: Dec 06 2025 at 07:03 UTC