<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/59596>59596</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Poor optimisation of back_inserter (with both libc++ and libstdc++)
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
DenisYaroshevskiy
</td>
</tr>
</table>
<pre>
On this example https://godbolt.org/z/1Mn69ExGb
GCC successfully optimises both cases while clang can only optimise one of them.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxckc2O2yAQx58GX9BaZvBHOHDYbOo9Ve21pwrwxNDFEHnwZtOnr5ymatUTzPf8_mOIwpwQNeuOrDtVZis-r_qEKdA3s2by-E5v4VbZPN30l8SLD8TxwyyXiNyXciEmnxmMDMY5TzbHUud1ZjD-ZDCKz6lXnz5eLWtOrHl-fXnhtDmHROctxhvPlxKWQEjc5uK5M_v36kNE7qJJM3cm8Zz-yeQ5Ic9nXjwudTVpOSmpTIVa9INoezWotvLaKSkEHHpnmgnOEoy1yjjb9pMUqmmHKmhoAAQIJYZGdW1tpFRStNIO5nyYRMfaBhcTYh3j-7ITVYFoQ92pTvVVNBYj3TUDSHjl9yAD2CVc9V7zZLeZWNvEQIX-dimhRNRfc17_IJkSctqRrHFv30MiXAuunMHhGor_LUwM1jE4Mjhyk6bdpDI9PAxUta1R_3eLUPxma5cXBuM-_fE8Xdb8A11hMN53JgbjnelXAAAA__8K2KoV">