[llvm] [Valuetracking] Use all FPClasses ordering information for min/max (PR #199651)
Niklas Ulvinge via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 1 05:16:30 PDT 2026
================
@@ -173,3 +173,24 @@ bool llvm::cannotOrderStrictlyLessEq(FPClassTest LHS, FPClassTest RHS,
bool OrderedZeroSign) {
return cannotOrderStrictlyGreaterImpl(RHS, LHS, true, OrderedZeroSign);
}
+
+FPClassTest llvm::orderedStrictlyLess(FPClassTest Mask) {
+ // Ignores NaN
+ unsigned NewMask = Mask & ~fcNan;
----------------
nulvinge wrote:
countr_zero, countl_zero, maskTrailingOnes, maskLeadingOnes only work on unsigned, so we must convert to unsigned, but I changed the type to FPClassTest, which made the code a bit cleaner.
https://github.com/llvm/llvm-project/pull/199651
More information about the llvm-commits
mailing list