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

    <tr>
        <th>Summary</th>
        <td>
            Assumptions not working with complex conditionals
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue,
            llvm:optimizations,
            missed-optimization
      </td>
    </tr>

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

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

<pre>
    https://godbolt.org/z/h14s5TGc5 is an example where a `__builtin_assume` containing an `||` conditional isn't working as expected. I wanted to assert that a value was in a particular range, and the expectation was that the `__builtin_assume` would result in the cases for 21 and 28 being optimized out. Removing the `||`, as in https://godbolt.org/z/ja5xsxoMo, does work as expected. See https://discourse.llvm.org/t/builtin-assume-with-complex-condition-not-working/73267 for more discussion.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyEU8tu2zoQ_RpqM5BB03rYCy1yE-iii27a7oOROLGYUqTBIWM3X1-QMZw0QFFAgAAdzuF5jJDZHB3RINr_RPtQYYqLDwOvRA5NNXn9a1hiPLHY3Qk1CjUevZ68jRsfjkKNr0KNy7bh9sf_cwuGAR3QBdeTJTgvFAgQRCcfH6dkbDTuEZnTSqKTMHsX0TjjjnlIdFL09_l5g7SJxju0YNgJ1Uc4-_CznGWgy4nmSHoDX-CMLpKG6AGZKUSIC0ZAeEGbCM7IYBwgnDBEMyeLAQK6Iwl1D-g0xIWudJjvKwOFIQN_EX72yWoIxMnGzJ6PzsjE8OQDqG0hVnuYKOv1p2hW80oafIob-Earf8nfrxfcTBdFRe2_8n7G9sIX_9XnEe2JSzZ_BvOd6BOPNjz7FJg21r6sV7oo1Hg1WL8ZrM8mLvXsc4OX-lZE7XysrxUINfY71fXF7uoDQeZOzMa7TaWHnT7sDljRsO0OjVRyv99Vy7Bt2qnbz_2h38-9VNg89c1eqq3GVk9SHyozKKl28iC7ba-2Sm7UQXdPDcmu7anVehaNpBWNvRmoDHOioWtb2VQWJ7Jc9lgpR2cooFBKqHuhVJ4Ru7trG6VsvoGrYSZdfwQz1j5UYciD9ZSOLBppDUd-vz6aaGm4y7mdCiE4_76oOUi4Bvlxo7lKwX7-qUxc0rSZ_SrUWKS-vepT8M8055qKHRZqLHZ_BwAA___ygj79">