[llvm] [InstCombine] Fold icmp(constants[x]) when the range of x is given (PR #67093)
Yingwei Zheng via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 29 01:19:07 PST 2023
================
@@ -209,21 +208,22 @@ Instruction *InstCombinerImpl::foldCmpLoadFromIndexedGlobal(
// Find out if the comparison would be true or false for the i'th element.
Constant *C = ConstantFoldCompareInstOperands(ICI.getPredicate(), Elt,
- CompareRHS, DL, &TLI);
+ ComparedRHS, DL, &TLI);
// If the result is undef for this element, ignore it.
if (isa<UndefValue>(C)) {
// Extend range state machines to cover this element in case there is an
// undef in the middle of the range.
- if (TrueRangeEnd == (int)i-1)
+ if (TrueRangeEnd == (int)i - 1)
----------------
dtcxzyw wrote:
Please commit these formatting fixes into main directly.
https://github.com/llvm/llvm-project/pull/67093
More information about the llvm-commits
mailing list