<div class="gmail_quote">2009/8/28 Andre Tavares <span dir="ltr"><<a href="mailto:andrelct@dcc.ufmg.br">andrelct@dcc.ufmg.br</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

Hello,<br>
<br>
in the description of SimplifyCFG, it says that it can "Eliminates PHI nodes for basic blocks with a single predecessor."<br>
<br>
I tested this pass with a program that has phi nodes with a single predecessor and it did not remove it. I also looked in the code and found nothing to remove it. I'm I missing something, or it does not remove phis with a single predecessor?</blockquote>

<div><br>This is probably better discussed in a bug report. I only took a brief look, but it looks like the problem is triggered by the CFG being diamond-shaped. The attached x.bc is a simpler testcase that also demonstrates the missed-optimization.<br>

<br>Nick</div></div><br>