-
Notifications
You must be signed in to change notification settings - Fork 13.4k
[AArch64][GlobalISel] llvm.fptoui.sat.i32.f128 miscompile #127804
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
Comments
@llvm/issue-subscribers-backend-aarch64 Author: Nikita Popov (nikic)
Per https://github.com/rust-lang/compiler-builtins/pull/760, LLVM 20 appears to be miscompiling fptoui.sat.i32.f128 on AArch64 when GlobalISel is used.
Assembly for LLVM 19 and LLVM 20: https://llvm.godbolt.org/z/n3K4MEG7r Likely related to #96297, cc @davemgreen |
Possibly I'm misreading the code, but I suspect that the select operands are inverted? llvm-project/llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp Lines 7818 to 7821 in 760ec2c
Src < MinFloat ? Src : MinFloat , but surely it should be Src < MinFloat ? MinFloat : Src ?
It doesn't really help that MaxC is referring to the minimum float... |
Hi - Yeah it sounds like I translated the code from using fminnum/fmaxnum badly.. Do you want me to put together a patch? |
Yes, please :) |
Pin aarch64-unknown-linux-gnu to nightly-2025-02-07 until [1] is resolved. [1]: llvm/llvm-project#127804
Pin aarch64-unknown-linux-gnu to nightly-2025-02-07 until [1] is resolved. [1]: llvm/llvm-project#127804
/cherry-pick 70ed381 |
/pull-request #128001 |
Pin aarch64-unknown-linux-gnu and aarch64-apple-darwin to nightly-2025-02-07 until [1] makes it to a Rust nightly. [1]: llvm/llvm-project#127804
Pin aarch64-unknown-linux-gnu and aarch64-apple-darwin to nightly-2025-02-07 until [1] makes it to a Rust nightly. [1]: llvm/llvm-project#127804
Pin aarch64-unknown-linux-gnu and aarch64-apple-darwin to nightly-2025-02-07 until [1] makes it to a Rust nightly. [1]: llvm/llvm-project#127804
Per rust-lang/compiler-builtins#760, LLVM 20 appears to be miscompiling fptoui.sat.i32.f128 on AArch64 when GlobalISel is used.
Assembly for LLVM 19 and LLVM 20: https://llvm.godbolt.org/z/n3K4MEG7r
Likely related to #96297, cc @davemgreen
The text was updated successfully, but these errors were encountered: