<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Oct 8, 2015 at 9:54 AM,  <span dir="ltr"><<a href="mailto:junbuml@codeaurora.org" target="_blank">junbuml@codeaurora.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">> I think this actually makes it less general. You would presumably perform<br>
> different inlining for:<br>
><br>
>   throw f(x, y);<br>
><br>
> versus<br>
><br>
>   auto k = f(x, y);<br>
>   throw k;<br>
<br>
</span>We need to differentiate between these two. For the second case, we should<br>
not add any attribute because it’s not invoked in the EH region and it<br>
could have any other purposes other than exception handling. I believe we<br>
need to specifically handle only the case where we can guarantee that the<br>
call is invoked only in exception handling context.</blockquote><div><br></div><div>Modulo copying the value returned by f, those two are equivalent, and it's entirely reasonable to want to refactor one into the other. Such refactoring should not affect the optimizer's behavior on this code. Why do you think they should be treated differently?</div></div></div></div>