[llvm] [InstCombine] Add combines for unsigned comparison of absolute value to constant (PR #176148)
Antonio Frighetto via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 15 06:48:25 PST 2026
================
@@ -4288,6 +4288,40 @@ Instruction *InstCombinerImpl::foldICmpIntrinsicWithConstant(ICmpInst &Cmp,
II->getArgOperand(1));
}
break;
+ case Intrinsic::abs: {
+ if (!Cmp.getOperand(0)->hasOneUse())
+ return nullptr;
+
+ Value *X = II->getArgOperand(0);
+ APInt IntMinIsPoison =
----------------
antoniofrighetto wrote:
IntMinIsPoison unused?
https://github.com/llvm/llvm-project/pull/176148
More information about the llvm-commits
mailing list