-
Notifications
You must be signed in to change notification settings - Fork 277
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
LLVM ERROR when test shift and insert methods in aarch64 #1017
Comments
It is most likely a bug in stdarch. Compare the LLVM IR generated by rustc with the IR generated by Clang for the equivalent C code. |
Oh actually I know what the problem is. The aarch64 intrinsics in stdarch currently only work in release builds because it is missing a This is in the process of being fixed as we are transitioning to using const generics in stdarch. |
Thanks for the explanation :) Is there a link to related work progress? I want to see if I can help |
The issue is #248, it has been open since 2017. At the moment we use Initial work on solving this issue properly has started in rust-lang/rust#82447. |
Thanks for the link. It looks like I can’t guarantee to fix it, but I will try my best :) |
[Edit] I just found out that vsri cannot accept n==0, so I think I need to rewrite a corresponding constify_* macro I just ran into some very weird problems:
It compiles and tests successfully, as are other vsli methods.
or this way
It still occurs LLVM ERROR:
But if I modify the first line of the match statement:
It will compile successfully and pass the test (the test value of n is 5). |
When I do the following test in
crates/core_arch/src/arm/neon/shift_and_insert_tests.rs#L33
on my aarch64:It has the following error:
The other methods in the test file will also have the same error. I am not sure if this is caused by llvm or something went wrong elsewhere
The text was updated successfully, but these errors were encountered: