<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/68445>68445</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
clang is 100x slower than gcc when compiling a large assembly source code
</td>
</tr>
<tr>
<th>Labels</th>
<td>
clang
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
TerrorJack
</td>
</tr>
</table>
<pre>
Reproducer: https://files.catbox.moe/59wc6g.zst
Extract the above `.tar.zst` file to get `ghc_3.s` which is around 110M. Compiling it via `gcc -c ghc_3.s -o ghc_3.o` takes about 5s on my laptop, while compiling it via `clang -c ghc_3.s -o ghc_3.o` takes about 8min.
Clang version: `Ubuntu clang version 17.0.2 (++20231003073128+b2417f51dbbd-1~exp1~20231003073233.51)`
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyMkruu3CAQhp8GN6NFXGx2Xbg4l2wRKU2U1BHgWZscbCzAe0lxnj3CZ6VspBRpADEz3-if-XVKbpgRO9I8k-a10mseQ-y-YYwhftb2rTKhv3VfcYmhXy1GIp9gzHlJRD4RcSTieHIeE7U6m3ClU0Aijk17sWqgv1Im7JWwp4_z0zVHbTPkEUGbcEYgitGs45aoGBQS5AAD5hIaRvtD0lQil9HZEVwCHcM698A5-0LhJUyL824ewGU4O70VWQs7C_da2IX7MxRM1m-YSu81Q5MgzDDdwOslh4WIl9LFI9h_UK3X8_B_3MPkZvoo-2WrPWNMLsxlfESx72ad8wr2MQR8TxkVQMSBiGcingUTkjMm2V7y7c-Imu9PDe-N6Xf8Ha8Lf39IElLShhPREsWqvpN9K1tdYcdVq5So2aGuxk5LRFTW8P5guaxre6pb0wjO2V4J2faV6-5IJZg4sJoqe9rzk-1Nb5TVXJKa4aSdp96fJxriULmUVuzUoa6bymuDPm12EmLTR4Qozopdyd-ZdUikZt6lnP4Qssseu49xuAScsSskHy4YIY96hrLVy4jzw3I0eB0HBJ0STsbfIIU12rK-Hqs1-u5vlw4uj6uhNkxEHEvf-7VbYviJNhNx3GQkIo6bkt8BAAD__z1O-KY">