[InstCombine] Canonicalize `and(zext(A), B)` into `select A, B & 1, 0` (#66740)

This patch canonicalizes the pattern `and(zext(A), B)` into `select A, B
& 1, 0`. Thus, we can reuse transforms `select B == even, B & 1, 0 -> 0`
and `select B == odd, B & 1, 0 -> zext(B == odd)` in `InstCombine`.
It is an alternative to #66676.
Alive2: https://alive2.llvm.org/ce/z/598phE
Fixes #66733.
Fixes #66606.
Fixes #28612.
GitOrigin-RevId: a7f962c00745c8e28991379985fcd6b51ac0d671
6 files changed