[PATCH] D74484: [AggressiveInstCombine] Add support for ICmp instr that feeds a select intsr's condition operand.
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 13 09:19:57 PST 2020
nikic added inline comments.
================
Comment at: llvm/lib/Transforms/AggressiveInstCombine/TruncInstCombine.cpp:356
+ Type *SrcTy = cast<CastInst>(I)->getSrcTy();
+ return Ty->getIntegerBitWidth() >= SrcTy->getIntegerBitWidth();
+ }
----------------
Doesn't the sext/zext case have to check the IsSigned flag as well? I don't think it's as simple as IsSigned => sext and !IsSigned => zext (e.g. it's fine if you have an equality comparison and both use same extension type), but same correctness checks are needed here.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74484/new/
https://reviews.llvm.org/D74484
More information about the llvm-commits
mailing list