[llvm] [LV] Peek through bitcasts when performing CSE (PR #146856)
Ramkumar Ramachandra via llvm-commits
llvm-commits at lists.llvm.org
Sun Aug 3 03:11:24 PDT 2025
================
@@ -2642,8 +2642,8 @@ namespace {
struct CSEDenseMapInfo {
static bool canHandle(const Instruction *I) {
- return isa<InsertElementInst>(I) || isa<ExtractElementInst>(I) ||
- isa<ShuffleVectorInst>(I) || isa<GetElementPtrInst>(I);
+ return isa<InsertElementInst, ExtractElementInst, ShuffleVectorInst,
+ GetElementPtrInst, BitCastInst>(I);
----------------
artagnon wrote:
I did a blame and found that this is really old code, that should probably be moved into VPlanTransforms: if you like, you can try to work on this as a follow-up?
https://github.com/llvm/llvm-project/pull/146856
More information about the llvm-commits
mailing list