Make ValueTracking directly call the KnownBits shift helpers, which provides more precise results.
Unfortunately, ValueTracking has a special case where sometimes we determine non-zero shift amounts using isKnownNonZero(). I have my doubts about the usefulness of that special-case (it is only tested in a single unit test), but I've reproduced the special-case via an extra parameter to the KnownBits methods.
what is the Known.getMaxValue().ult(Known.getBitWidth()) is doing here?