<div class="gmail_quote">On 31 October 2011 10:23, Owen Anderson <span dir="ltr"><<a href="mailto:resistor@mac.com">resistor@mac.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

Nick,<br>
<br>
Isn't what you're computing here an approximation of immediate post-dominance?  If we really want to handle this properly, it seems like we should just use the actual post-dominance computation rather than approximating it.<br>

</blockquote><div><br></div><div>Heh, an earlier version of my patch actually called that function FindPostIdoms.</div><div><br></div><div>No, simply looking at postdoms would actually do the wrong thing. Consider a CFG "A -> {B, C}, B -> D, C -> D": the matching postdom tree is "D -> {A, B, C}". Given a free in block D we would look for and delete stores in A. Trouble is, those aren't necessarily dead as there may be uses in B and C. That's why I explicitly check through the preds.</div>

<div><br></div><div>Nick</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">--Owen<br>
<div><div class="h5"><br>
On Oct 31, 2011, at 1:54 AM, Nick Lewycky wrote:<br>
<br>
> This patch teaches DSE to look for blocks that will unconditionally land in the particular free call, when handling a call to free. This is important for std::vector, see PR11240.<br>
><br>
> Please review!<br>
><br>
> Nick<br>
</div></div>> <pr11240-1.patch>_______________________________________________<br>
> llvm-commits mailing list<br>
> <a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
> <a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div><br>