[llvm] [InstCombine] Move alignment assumptions to the base of constant offset GEPs (PR #204602)
Nikolas Klauser via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 18 08:37:59 PDT 2026
================
@@ -3686,6 +3686,15 @@ Instruction *InstCombinerImpl::visitCallInst(CallInst &CI) {
return RemoveBundle();
}
+ Value *BasePtr;
+ uint64_t PtrOffset;
+ if (match(Ptr.get(),
+ m_PtrAdd(m_Value(BasePtr), m_ConstantInt(PtrOffset)))) {
----------------
philnik777 wrote:
It seems that constants in GEPs always get sign-extended, so I don't think that's observable?
https://github.com/llvm/llvm-project/pull/204602
More information about the llvm-commits
mailing list