[ValueTracking] Use maximum shift count in `shl` when determining if `shl` can be zero.
Previously only return `shl` non-zero if the shift value was `1`. We can expand this if we have some bounds on the shift count. For example: ``` %cnt = and %c, 16 ; Max cnt == 16 %val = or %v, 4 ; val[2] is known one %shl = shl %val, %cnt ; (val.known.one << cnt.maxval) != 0 ``` Differential Revision: https://reviews.llvm.org/D147897
Loading
Please sign in to comment