[llvm] [ValueTracking] Implement `computeKnownFPClass` for `llvm.vector.reduce.{fmin,fmax,fmaximum,fminimum}` (PR #88408)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 11 10:20:19 PDT 2024
================
@@ -5004,6 +5004,15 @@ void computeKnownFPClass(const Value *V, const APInt &DemandedElts,
break;
}
+ // reduce min/max will choose an element from one of the vector elements,
+ // so we can infer and class information that is common to all elements.
+ case Intrinsic::vector_reduce_fmax:
+ case Intrinsic::vector_reduce_fmin:
+ case Intrinsic::vector_reduce_fmaximum:
+ case Intrinsic::vector_reduce_fminimum:
+ computeKnownFPClass(II->getArgOperand(0), Known, InterestedClasses,
----------------
goldsteinn wrote:
I need to add proofs for all of the cases. I will do so before proceeding w/ this.
https://github.com/llvm/llvm-project/pull/88408
More information about the llvm-commits
mailing list