[PATCH] D137934: [InstCombine] Fold extractelt with select of constants
Jay Foad via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 15 01:08:26 PST 2022
foad added inline comments.
================
Comment at: llvm/lib/Transforms/InstCombine/InstructionCombining.cpp:1101
+ const uint64_t IndexVal = Idx->getValue().getZExtValue();
+ auto *TrueConst = dyn_cast<Constant>(TrueVal->getAggregateElement(IndexVal));
+ auto *FalseConst =
----------------
Don't need a cast. getAggregateElement already returns Constant.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D137934/new/
https://reviews.llvm.org/D137934
More information about the llvm-commits
mailing list