[llvm] [InstCombine] Treat `asin`, `asinh`, `atan`, `atan2` and `cbrt` as odd-functions (PR #227336)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 29 10:46:14 PDT 2026
================
@@ -11,7 +16,9 @@ declare void @use(double) nounwind
define double @test_erf(double %x) {
; CHECK-LABEL: define double @test_erf(
; CHECK-SAME: double [[X:%.*]]) {
-; CHECK-NEXT: [[RES:%.*]] = tail call reassoc double @erf(double [[X]])
+; CHECK-NEXT: [[NEG_X:%.*]] = fneg double [[X]]
+; CHECK-NEXT: [[RES1:%.*]] = tail call reassoc double @erf(double [[NEG_X]])
+; CHECK-NEXT: [[RES:%.*]] = fneg double [[RES1]]
----------------
suogesi wrote:
I've run `make check-llvm` and found `atan2` is not working as I imaginated. I hope this time it is as expected.
https://github.com/llvm/llvm-project/pull/227336
More information about the llvm-commits
mailing list