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

    <tr>
        <th>Summary</th>
        <td>
            [DirectX] The dx.saturate intrinsic is not being scalarized
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            backend:DirectX
      </td>
    </tr>

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

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

<pre>
    As seen in https://github.com/llvm-beanz/offload-test-suite/pull/62, using HLSL's "saturate" operation on a vector is resulting in an `error: Cannot create Saturate operation: Invalid overload type` from the backend. This is because the intrinsic isn't being scalarized and there is no vector DXIL op when we try to lower.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyEUrFu2zAU_BpqeYggP8pWNGhwYwgNkC0ZslLkk8SWJgW-J6fJ1xdyYwTt0pl3x7t3Z5j9FIk6tf-m9qfCrDKn3A1pipSLIbn37sjARBF8hFlkYaWPCnuF_eRlXofSprPCPoTL-W4gEz8U9mkcQzLuTojljlcvpLBf1hAU9gdU-AAr-zjB96fnJ4UNg0JkI2s2GxIhLZSN-BQhRTBwISspg2fIxGuQjeojmAjqUFHOKSt9hAcTYxKwmYwQPH_KfWltmMd4McE7SBfKm0OQ94XUoYIxpzPITDAY-5OiK-Fl9rx9OZA1K9P10UfJPrK34DkqbAQG2sywNcFk_0EOTHQbNNPGjenm_fT6-ARpgbeZIrwRSH4HSRDSG-WycJ12rW5NQd2uqXXT6J2ui7mzTjsch6o60L1Da_Zt60ZT6bE-6LFGLHyHFe6ruqp3Gve6Lm3bWtvo-53BBis3qrqis_Gh3PopU54Kz7xSt9O1bu6LYAYKfC0f8TO60seTz2TlVSFum8jdn3LXiVVdBc_CX3LiJVzXc-PsT_AyE7hf5a3Rv84GW0f_Xq1Yc-j-M67bxpacfpAVhf01CSvsP8NcOvwdAAD__9RP75s">