<div>
                    Hi there,
                </div><div><br></div><div>I'm trying to get a list of predecessors of a BasicBlock. I'm using a code similar to that on <a href="http://llvm.org/docs/ProgrammersManual.html#iterate_preds">here</a>, but it appears to be more nodes been iterating that it should. Now, when I print out the llvm IR, I get something like:</div><div><span>[…]</span></div><div><span>while.body:                                       ; preds = <font color="#ff2a1a">%7, %while.cond</font></span></div><div><span>[…]</span></div><div><span>for a code that have only a while loop. Ok, I can recognize the %while.cond block on the code, but the %7 block seems to be an extra BasicBlock (I mean, it is not directly represented in the IR) that holds only a copy of the branch instruction that ends the %while.cond block. </span></div><div><span><br></span></div><div><span>Here is the question: is there any way that I could discard these blocks that are not represented in the IR?</span></div>
                <div><div><br></div><div>Thanks in advance,</div><div><br></div><div>-- </div><div>Cristianno Martins</div><div>PhD Student of Computer Science</div><div>University of Campinas</div><div>cmartins@ic.unicamp.br</div></div>