[llvm] [InstCombine] Fold select of clamped shifts (PR #114797)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 4 07:49:13 PST 2024
nikic wrote:
> > I think that #97289 might cover this?
>
> We should call `SimplifyDemandedBits` on the RHS of shift operators.
Maybe it would be best to not actually base it on SimplifyDemandedBits, and just use a separate recursive simplification that only does basic known bits simplification like dropping bitwise ops. It seems like SimplifyDemandedBits can have too many undesirable effects, and as you say, may also not recurse everywhere we want for this purpose.
https://github.com/llvm/llvm-project/pull/114797
More information about the llvm-commits
mailing list