<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 10, 2016 at 2:44 PM, Piotr Padlewski <span dir="ltr"><<a href="mailto:piotr.padlewski@gmail.com" target="_blank">piotr.padlewski@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Prazek added a comment.<br>
<span class=""><br>
In <a href="https://reviews.llvm.org/D23339#511891" rel="noreferrer" target="_blank">https://reviews.llvm.org/<wbr>D23339#511891</a>, @mehdi_amini wrote:<br>
<br>
> In <a href="https://reviews.llvm.org/D23339#511890" rel="noreferrer" target="_blank">https://reviews.llvm.org/<wbr>D23339#511890</a>, @eraman wrote:<br>
><br>
> > In <a href="https://reviews.llvm.org/D23339#511869" rel="noreferrer" target="_blank">https://reviews.llvm.org/<wbr>D23339#511869</a>, @mehdi_amini wrote:<br>
> ><br>
> > > LGTM, thanks.<br>
> > >  We probably need to review other properties of function that prevents them from being inlined.<br>
> ><br>
> ><br>
> > This check should be eventually moved to InlineCost so that importer and inliner are out of sync. For now, a FIXME should be useful.<br>
><br>
><br>
> Very good point indeed.<br>
<br>
<br>
</span>So we could check all attributes but they are so not frequent that it wont make huge difference like this one. If the checks are in O(1) then it probably make sense to move them eventually, but things like traversing all instructions to check if function is recursive and other would not make much sense as these functions or instructions are not that frequent (imho)<br></blockquote><div>They are not frequent in Spec does not necessarily mean they are not useful to check. In any case my point is that the logic should reside in InlineCost where we could choose to do only the inexpensive checks (even if it is just this one). </div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
<a href="https://reviews.llvm.org/D23339" rel="noreferrer" target="_blank">https://reviews.llvm.org/<wbr>D23339</a><br>
<br>
<br>
<br>
</blockquote></div><br></div></div>