<div dir="ltr"><div>Well, what I had in mind was actually something like the following:<br><br>entry:<br>  result0 = invoke func0 to defer_block unwind landing0<br><br>landing0:<br>  landingpad<br>  result1 = invoke func1 to defer_block unwind landing1<br>
<br>landing1:<br>  landingpad<br>  br defer_block<br><br>defer_block:<br>  result = phi [ result0, entry ], [ result1, landing0 ], [ null, landing1 ]<br>  ...<br><br></div><div>This doesn't have landing pads with multiple predecessors like he said,<br>
but I don't think that would make much difference.<br>The "defer block", however, is the target of multiple invokes.<br></div><div>I hope this makes sense. : )<br><br>H.<br></div><br><div><br></div></div><div class="gmail_extra">
<br><br><div class="gmail_quote">On Mon, Nov 4, 2013 at 1:54 PM, Rafael Espíndola <span dir="ltr"><<a href="mailto:rafael.espindola@gmail.com" target="_blank">rafael.espindola@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On 4 November 2013 02:31, Henrique Santos<br>
<div class="im"><<a href="mailto:henrique.nazare.santos@gmail.com">henrique.nazare.santos@gmail.com</a>> wrote:<br>
> But the incoming value from the landing pad will always be null, won't it?<br>
> If so, just iterate through the predecessors and add the terminator as the<br>
> incoming value if it's an invoke instruction and add the null value it's<br>
> not.<br>
> Won't that work?<br>
><br>
<br>
<br>
</div>Note that the return value of an invoke is defined on the *edge* of<br>
the successful return. So you cannot have a path to a use that goes<br>
through the exception instead. In your example you have:<br>
<br>
landing -> defer_block -> next_step.<br>
<br>
This Is a static property, so this code in invalid even if dynamically<br>
this path is never taken.<br>
<br>
Cheers,<br>
Rafael<br>
</blockquote></div><br></div>