saulecabrera requested abrown for a review on PR #10263.
saulecabrera requested wasmtime-compiler-reviewers for a review on PR #10263.
saulecabrera opened PR #10263 from saulecabrera:winch-sync-sp-ssp-on-drop
to bytecodealliance:main
:
This commit is a follow-up to
https://github.com/bytecodealliance/wasmtime/pull/10146 and represents another step toward fixing the remaining issues discovered through spec tests in the same vein as https://github.com/bytecodealliance/wasmtime/pull/10201Specifically, this commit ensures that the stack pointer is always in sync with the shadow stack pointer. The previous approach was lossy because it only performed the sync when reserving stack space. While this approach worked in some cases, it failed to account for situations where the shadow stack pointer might be adjusted and aligned for calls. As a result, the stack pointer could become unaligned when claiming stack space, leading to issues at call sites.
It is possible to avoid the unconditional move and perform it only when alignment is needed, i.e., at call sites and when the real stack pointer is unaligned. However, as of now, the simplest solution is to always perform the sync, which integrates best with the current infrastructure.
<!--
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
-->
saulecabrera requested dicej for a review on PR #10263.
saulecabrera requested wasmtime-core-reviewers for a review on PR #10263.
saulecabrera updated PR #10263.
saulecabrera commented on PR #10263:
The diff is considerably large, since this change touches all of the disassembly tests for aarch64. The relevant changes are in the first commit https://github.com/bytecodealliance/wasmtime/pull/10263/commits/97d7f740b8180358fd1aef63a5f12cc35d59374c
saulecabrera updated PR #10263.
alexcrichton submitted PR review.
alexcrichton merged PR #10263.
Last updated: Feb 28 2025 at 03:10 UTC