(srl (not X), N-1) is either 0/1, so any zext can be combined to
this.
To avoid the transformation when the result of the setcc is being
used directly, only allow mismatch if the zext type is larger than
i8.
Differential D145002
[DAGCombiner] Make `(zext (sgt X, -1))` -> `(srl (not X), N-1)` work if typeof(zext)!=typeof(X) goldstein.w.n on Feb 28 2023, 1:20 PM. Authored by
Details
(srl (not X), N-1) is either 0/1, so any zext can be combined to To avoid the transformation when the result of the setcc is being
Diff Detail
Event Timeline
Comment Actions Fix add + sext case
Comment Actions Remove dead comment
|