[PATCH] D67677: [InstCombine] dropRedundantMaskingOfLeftShiftInput(): pat. a/b with mask (PR42563)
Roman Lebedev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 19 09:20:43 PDT 2019
lebedev.ri added inline comments.
================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp:176-180
+ Type *ExtendedScalarTy = Type::getIntNTy(Ty->getContext(), 2 * BitWidth);
+ Type *ExtendedTy =
+ Ty->isVectorTy()
+ ? VectorType::get(ExtendedScalarTy, Ty->getVectorNumElements())
+ : ExtendedScalarTy;
----------------
spatel wrote:
> Is there a test showing that we need this ext+trunc complexity?
>
> See if I've botched this Alive somehow, but the simpler constant mask appears to work:
> https://rise4fun.com/Alive/ArQC
Hmm. The reason i've gone forward with ext/trunc is: https://rise4fun.com/Alive/o5l
In your example alive does not complain because those are constants, and somehow the usual poison rules don't apply?
Are we sure this isn't alive limitation, but the correct behavior?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D67677/new/
https://reviews.llvm.org/D67677
More information about the llvm-commits
mailing list