[llvm] PowerPC/VSX: Select FMINNUM_IEEE and FMAXNUM_IEEE (PR #112195)
Lei Huang via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 22 13:30:38 PDT 2024
================
@@ -2735,39 +2744,23 @@ def : Pat<(f32 (fneg (fabs f32:$S))),
// f32 Min.
def : Pat<(f32 (fminnum_ieee f32:$A, f32:$B)),
(f32 FpMinMax.F32Min)>;
-def : Pat<(f32 (fminnum_ieee (fcanonicalize f32:$A), f32:$B)),
- (f32 FpMinMax.F32Min)>;
-def : Pat<(f32 (fminnum_ieee f32:$A, (fcanonicalize f32:$B))),
- (f32 FpMinMax.F32Min)>;
-def : Pat<(f32 (fminnum_ieee (fcanonicalize f32:$A), (fcanonicalize f32:$B))),
+def : Pat<(f32 (fminnum f32:$A, f32:$B)),
(f32 FpMinMax.F32Min)>;
// F32 Max.
def : Pat<(f32 (fmaxnum_ieee f32:$A, f32:$B)),
(f32 FpMinMax.F32Max)>;
-def : Pat<(f32 (fmaxnum_ieee (fcanonicalize f32:$A), f32:$B)),
- (f32 FpMinMax.F32Max)>;
-def : Pat<(f32 (fmaxnum_ieee f32:$A, (fcanonicalize f32:$B))),
- (f32 FpMinMax.F32Max)>;
-def : Pat<(f32 (fmaxnum_ieee (fcanonicalize f32:$A), (fcanonicalize f32:$B))),
+def : Pat<(f32 (fmaxnum f32:$A, f32:$B)),
(f32 FpMinMax.F32Max)>;
----------------
lei137 wrote:
I feel I am missing something. These pattern changes indicates that `fmaxnum_ieee` is the same as `fmaxnum`? Which seems wrong to me. The scalar-min-max.ll tests for `xsmaxcdp|xsmincdp` have now changed to use `xsmaxdp|xsmindp`?
https://github.com/llvm/llvm-project/pull/112195
More information about the llvm-commits
mailing list