[llvm] [InstCombine] Drop wrong ninf for `(-X / Y) + Z` (PR #228684)

via llvm-commits llvm-commits at lists.llvm.org
Sat Oct 3 12:09:46 PDT 2026


================
@@ -2167,7 +2167,9 @@ Instruction *InstCombinerImpl::visitFAdd(BinaryOperator &I) {
                          m_Value(Z))) ||
       match(&I, m_c_FAdd(m_OneUse(m_FDiv(m_Value(X), m_FNeg(m_Value(Y)))),
                          m_Value(Z)))) {
-    Value *XY = Builder.CreateFDivFMF(X, Y, &I);
+    Value *Div = I.getOperand(0);
----------------
suogesi wrote:

Case 1 is added with name `fdiv_fneg*_ninf` and Case 2 is renamed to `fdiv_fneg*_ninf_does_not_propagate_to_div` now.

https://github.com/llvm/llvm-project/pull/228684


More information about the llvm-commits mailing list