<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/136107>136107</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
missed optimization (LLVM)?
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
alex-s168
</td>
</tr>
</table>
<pre>
https://godbolt.org/z/bxs4zvWj7
I don't know if that is supposed to be like this for some reason, but it could just be simplified to:
```
i64 fn(i64* ptr, i64 len) {
return (len == 0) ? 1 : ptr[0]
}
```
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJxckUGL5C4QxT9N5VJMY9Qk5uAh_W8Cf5i97p5Np-zYY2KIpme2P_1itmGXBUHQeq8e72didLeFSEN1hupSmD1NYdPG09dbLGtVDGH8qaeU1giiA94D729hHIJPp7DdgPdP4P3wFeXz8ePeAOuAdf_jGBbgTcKPJXyis5gmk9BFjPu6hkgjpoADoXcfhGlyEW3YMIaZcCMTs_g_HPaELuE17H7E-x5TVkQ3r95Zd1jkRKyDmr0O61wt0S7Alasl8A7XtGWr_OxpAd4iNGdgHeJGad8WBK48LQjiAuKC7JgQPZYI4re6OjOoLnlNc_l7WTFqMbaiNQXpspFSNS1Topi0kLwhSbI0rRyUstY2JZFVZpTKllYUTnPGKybLhimhmDjVUrGqppHslRkSFiSj2Th_8v4x55YLF-NOuhR1yZrCm4F8PIBxvtAnHr_Aeea36Sx6G_ZbBMm8iyn-sUkuedKzi5lAWJOb3dMkF44a3t-_fwPeguiLffP_Indp2ofTNczA--z3ut7WLdzpmoD3R4oIvH_FfGj-KwAA__9i6rfF">