jeffcharles opened PR #7449 from jeffcharles:winch-popcnt-should-check-sse-flag
to bytecodealliance:main
:
<!--
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
-->
I noticed a failure in Winch's fuzzing with the following:(module (type (;0;) (func (param i64) (result i64))) (func (;0;) (type 0) (param i64) (result i64) local.get 0 i64.popcnt ) (export "test" (func 0)) )
with a configuration where
has_popcnt
was set totrue
buthas_sse42
was set tofalse
with an error message saying:Cannot emit inst 'popcntq %rax, %rax' for target; failed to match ISA requirements: [Popcnt]
I was able to reproduce the error message with the two new file tests in this PR.
Adding a check in the macroassember to use the fallback if either flag is missing appears to resolve the issue.
jeffcharles requested fitzgen for a review on PR #7449.
jeffcharles requested wasmtime-compiler-reviewers for a review on PR #7449.
fitzgen submitted PR review:
Thanks!
fitzgen has enabled auto merge for PR #7449.
fitzgen merged PR #7449.
Last updated: Nov 22 2024 at 17:03 UTC