Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Register allocation panic in Wasmtime v0.35.2 #4010

Closed
ulan opened this issue Apr 11, 2022 · 4 comments
Closed

Register allocation panic in Wasmtime v0.35.2 #4010

ulan opened this issue Apr 11, 2022 · 4 comments
Labels
bug Incorrect behavior in the current implementation that needs fixing

Comments

@ulan
Copy link
Contributor

ulan commented Apr 11, 2022

After upgrading to version 0.35.2 we are seeing register allocation panics in our integration tests:

thread '<unnamed>' panicked at 'register allocation: Analysis(EntryLiveinValues([v430V]))',
cranelift-codegen-0.82.2/src/machinst/compile.rs:98:10

The panic seems to be fixed on the main branch.

The regression bisects to #3682 and the fix bisects to #3934, which looks related because v430V appears in ucomiss instructions:

  Inst 893:   cmovnzq %v588J, %v429J; cmovpq  %v588J, %v429J
  Inst 894:   xorps   %v585V, %v585V
  Inst 895:   ucomiss %v585V, %v430V
  Inst 896:   setp    %v586Jb

I can share the complete output of VCode_ShowWithRRU if that would help.

I don't have a standalone Wasm file that reproduces this panic, but I can try to extract it from the integration test if that would help.

@ulan ulan added the bug Incorrect behavior in the current implementation that needs fixing label Apr 11, 2022
@ulan
Copy link
Contributor Author

ulan commented Apr 11, 2022

@abrown @cfallin: Should #3934 be cherry-picked to v0.35?

@cfallin
Copy link
Member

cfallin commented Apr 11, 2022

@ulan thanks for this report; it certainly looks like the bug that we fixed in #3934. I'm trying to work out now what happened, and it looks like at the time we made the fix, we missed that the original bug was old enough to have gone out in the 0.35 release. I will go ahead with the patch-release process and prepare 0.35.3 with the fix.

@ulan
Copy link
Contributor Author

ulan commented Apr 11, 2022

Thanks for the fast response and cherry-pick @cfallin!

@cfallin
Copy link
Member

cfallin commented Apr 11, 2022

@ulan this workflow is running now to publish new crates for 0.35.3; please let us know if there are any other issues! I'll go ahead and close this issue now.

@cfallin cfallin closed this as completed Apr 11, 2022
dfinity-bot pushed a commit to dfinity/ic that referenced this issue Apr 13, 2022
EXC-1026: Upgrade wasmtime 0.35.3

Release notes of 0.35.3: https://github.com/bytecodealliance/wasmtime/blob/main/RELEASES.md#0353

Diff between 0.35.3 and 0.34.1: bytecodealliance/wasmtime@v0.34.1...v0.35.3

The previous upgrade to 0.35.2 was reverted due to a bug in wasmtime:
bytecodealliance/wasmtime#4010

0.35.3 fixes that bug and we can continue with upgrading. 

See merge request dfinity-lab/public/ic!4322
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Incorrect behavior in the current implementation that needs fixing
Projects
None yet
Development

No branches or pull requests

2 participants