Add the ability to computeKnownBits and SimplifyDemandedBits to extract the known zero/one bits from a BUILD_VECTOR, returning the known bits that are shared by every vector element.
This is an initial step towards determining the sign bits of a vector (PR29079).
It would be clearer if you initialized KnownOne and KnownZero to all ones at the start of the loop and replace the conditional with the else case.