[DAGCombiner] Combine `(select c, (and X, 1), 0)` -> `(and (zext c), X)`
The middle end canonicalizes: `(and (zext c), X)` -> `(select c, (and X, 1), 0)` But the `and` + `zext` form gets better codegen.
Loading
Please sign in to comment
The middle end canonicalizes: `(and (zext c), X)` -> `(select c, (and X, 1), 0)` But the `and` + `zext` form gets better codegen.