<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/58589>58589</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            Remove !IsLogical conditions in foldAndOrOfICmps()
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            llvm:instcombine,
            missed-optimization
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          nikic
      </td>
    </tr>
</table>

<pre>
    foldAndOrOfICmps() currently contains a number of `!IsLogical` checks: https://github.com/llvm/llvm-project/blob/e95c74b423c4c78102121e0d7cd8479450a285df/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp#L2614

These should be removed where legal, or handled by inserting `freeze` where not.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyVkV1r5SAQhn-NuZEGNfEkufDi7CmFA4VC6cXe-jFJ3BoNalpOf_2alLJd2JsVcRyGeZ33UQVzE2Nw5uzNU3war5dlTYj1iA1YbzGCz-6GdfBZWp-wxH5bFEQcRoxOBDF6TY9hslq6kmI9g35NqDnjOed1vyD2UPZk87ypWoelJM69fYW7NYZfoHNJlQuqBBi47lrVska3uuspYZRRIKbTpm-7oeVEsp6b8ZuO3fteovRpDHEpwz9cfcqXsCjr4e_sMPkzxFqvK2LNIzvRFpF7RM6f58sMCXCaw-YMVoAjLOENDH6fIQJ2MBWb7IJDxLP0xpWKuuHCBWK2ftqJjBHgA3YWnz0-5LoCQU9lDbQ98cqIxgzNIKtsswPxfDyBv5PccRubbSjArcf__p1qi078N2Wb0gY7It7zfqhmQTiTnPKBsq6VkkptdMOHFijQUY19VzmpwCWB-A_E2CHanIvjrL_4sp1ICUvRBnMX1mwX-yH38fciv6-sYISx8pWcDJwSXnfcsIYTA3ykfd9r1BJYpHX1rl-HOFVRHIOrbUql6GzK6U9RpmQnD3AMVfTllucQhbevVleHQ3HY-w05MetI">