-
Notifications
You must be signed in to change notification settings - Fork 824
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
Fix singlepass for Aarch64 #3415
Conversation
…kend (using MOVN)
…rect opcode (for #3343)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add a test verifying the fix? (triggering what was failing)
Otherwise it looks good
I can try using the wasi test suite facility, that seems the more sane way to be sure to reproduce the issue (needs a .rs compile, so comparing between native / wasm as the wasi testdoes seems the best way). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As Syrus said, a test would be great.
We should try to get into the habit of adding regression tests for each bug we fix.
Adding the Rust reproduction sounds good.
Would be nice to also have a minimal .wat
test case, but probably not worth spending extra time on that if it's not trivial to recreate.
In the future we might also want to have some (singlepass) codegen snapshot tests.
As in: test that a specific input compiles to the expected Assembly.
Yeah, well. |
👍 I actually also wanted to mention above: we really need to get M1 CI up and running. |
bors r+ |
Build succeeded: |
Description
Following debug of ticket #3343 , some issues in the singlepass were found.
In particular, some ADD/SUB opcode involving XSp with large value were not using the correct opcode, and
sub xsp, xsp, x17
were encoded asneg xzr, x17
(a.k.a.sub xzr, xzr, x17
). By forcing the dummyUXTX
modifier, the correct opcode is selected.Changed both SUB and ADD emiters.
Some alignement function specific to macOS ABI were also adjusted, and Local variable storage/retreival optimized a bit.