[llvm] X86: Return canonicalized result from LowerFMINIMUM_FMAXIMUM (PR #123868)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 21 19:37:30 PST 2025


================
@@ -29058,7 +29058,8 @@ static SDValue LowerFMINIMUM_FMAXIMUM(SDValue Op, const X86Subtarget &Subtarget,
   SDValue IsNaN =
       DAG.getSetCC(DL, SetCCType, NewX, NewX, IsNum ? ISD::SETO : ISD::SETUO);
 
-  return DAG.getSelect(DL, VT, IsNaN, NewX, MinMax);
+  MinMax = DAG.getSelect(DL, VT, IsNaN, NewX, MinMax);
----------------
arsenm wrote:

It shouldn't be required to canonicalize the result under the current rules. You would need the canonicalize handling for the strict variant, but that doesn't appear to be handled here 

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


More information about the llvm-commits mailing list