elliottt opened PR #8215 from elliottt:main
to bytecodealliance:main
:
The Winch calling convention in Cranelift wasn't respecting
uext
orsext
annotations, which resulted in it clobbering multi-value returns when some of the returned results were smaller than 8 bytes. This PR fixes the issue by falling back on the default result offset rules when argument extension attributes are provided on return values.This doesn't affect trampolines used by Winch itself, as we never emit argument alignment annotations on those trampolines.
<!--
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
-->
elliottt requested abrown for a review on PR #8215.
elliottt requested wasmtime-compiler-reviewers for a review on PR #8215.
elliottt requested alexcrichton for a review on PR #8215.
elliottt updated PR #8215.
elliottt updated PR #8215.
elliottt edited PR #8215:
The Winch calling convention in Cranelift wasn't respecting
uext
orsext
annotations, which resulted in it clobbering multi-value returns when some of the returned results were smaller than 8 bytes. This PR fixes the issue by falling back on the default result offset rules when argument extension attributes are provided on return values.Additionally, the handling of
i128
for the winch calling convention was producing impossible regalloc constraints, so I've modified the loop that processes result slots to only place the last slot in a register, rather than the last param. I've also disabled simd fuzzing for winch in the function generator.This doesn't affect trampolines used by Winch itself, as we never emit argument alignment annotations on those trampolines.
<!--
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
-->
elliottt updated PR #8215.
alexcrichton submitted PR review.
alexcrichton merged PR #8215.
Last updated: Nov 22 2024 at 17:03 UTC