[llvm] [ConstraintElimination] Add support for UCMP/SCMP intrinsics (PR #97974)

via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 10 11:56:40 PDT 2024


================
@@ -1750,6 +1774,8 @@ static bool eliminateConstraints(Function &F, DominatorTree &DT, LoopInfo &LI,
         Changed |= Simplified;
       } else if (auto *MinMax = dyn_cast<MinMaxIntrinsic>(Inst)) {
         Changed |= checkAndReplaceMinMax(MinMax, Info, ToRemove);
+      } else if (auto *CmpIntrinsic = dyn_cast<class CmpIntrinsic>(Inst)) {
----------------
Poseydon42 wrote:

That doesn't work because the variable has the same name as the class, so the compiler assumes that the variable is used in its own initializer.

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


More information about the llvm-commits mailing list