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

    <tr>
        <th>Summary</th>
        <td>
            clang-cl: Cannot explicitly request assembler-with-cpp
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

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

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

<pre>
    When using clang-cl as assembler it will automatically use the preprocessor when specifying the assembly filename as `.S`.
However it should be possible to run the preprocessor  on any file extension using `-xassembler-with-cpp` as with gcc.
Trying to pass the arument directly to clang-cl produces `clang-cl: warning: unknown argument ignored in clang-cl: '-xassembler-with-cpp' [-Wunknown-argument]`
Trying to pass it using `-Xclang -xassembler-with-cpp` or `/clang:-xassembler-with-cpp` will result in warnings like below:
```
clang-cl: warning: argument unused during compilation: '-D HOST_IA32' [-Wunused-command-line-argument]
clang-cl: warning: argument unused during compilation: '-D TARGET_IA32' [-Wunused-command-line-argument]
clang-cl: warning: argument unused during compilation: '-D TARGET_WINDOWS' [-Wunused-command-line-argument]
clang-cl: warning: argument unused during compilation: '/showIncludes' [-Wunused-command-line-argument]
```
And the preprocessor symbols defined will not be known in the assembly
Just to be clear: The exact same command will work perfectly if instead of trying to specify '-xassembler-with-cpp'  I just use a filename with a `.S` extension
I am not sure if this behavior should be considered a bug or a feature request
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzFVdtu4zYQ_RrpZSBDl5XtPOjBbZqu92EXaAKkbwVFjixuKFLlJYr_vkPJdpJmU2CBYhcQbPF2zpnhzFFrxLG571FDcFIfgCumDxlXwBw9DodWoQXpYZKKJoM3A_OSM6WOdALB9wijxdEajs4ZC1PEciNy2R0jYNxwAjpCJxVqNsQZSNb56jb-JPl1ku8-mgkfFyrXm6AEtIRsnJOkALwBG_RbNjAamF6AAZ88aifNORYCz54uQWST9H3Gx5GmI38cwoHzE_-dXeQaGOnIItuGAbUHIS1yT_Jp8ZIf0iACqYgs58mk2sHErCag-Br0gzYTCbSHBUgetLEoQGp4eSQpN9_UWW4gqX_J7k842Rknqa-J9JuyKXvPsf85k8B7OaD0RZjyZt5GQt7bOF-9RReUj9JPETpQ8gHplpSZ6PAiJwIuzzx8JzGXhARNNSRABDvXnhlGqai8jD6n5Ro-frm9-2u_q8oX6YiHMto9MC0yJTW-Ss3_xXy3--P3334u9_3-8_WX-9sfS08VQR047TVXQaD7PvJ_FcBOi7dN645Da5QDgR1hiKW-tPGx45eOkfqVbyxYn4LzsdBpF1fIbJR718e2Z5xMI9rKSduCOBn7ACPabmle2RGs88gEmA78pW9OXvVfXQh7-BrJo-GxZxObHYRdjOzZfxa9e2DDHJYLFiO976Uj9T17lDELF5fjhk4JjM7AoA2H2JlEg8zHgxb_Duh8ik2xXq_LbX21WaeiqcRVdcVSL73C5uWV_8p0JMWnUUkuY-QnBHgbXBqsanrvRxc7uLyh50BLoV1RJmmg1OP5L6P7-0qZpKF0LsS6uKm3db5O-2bDRL7utttqW9V801W8YhV2ZVtcFW2xZZgqRjbhGiqjpCw1TjBD0DvVTSqbMi_LIi_zYlOUdb3aiLLGghWMsNZYbpMPOQ5MqlXUsTL2kNpmlkS5crSopPPueZHCJKNFnOkInz5avbHN6DhrjU9n6maW_g_f9F1h">