Displaying 1 result from an estimated 1 matches for "dummy_bb".
Did you mean:
dummy_1
2004 Dec 07
1
[LLVMdev] Question adding dummy basic blocks
...due to PHINODE. I knew the reason, but I failed to fix it.
The code is like the following
if( TI->getNumSuccessors() ==1){
BasicBlock *TIBB=TI->getParent();
BasicBlock *DestBB=TI->getSuccessor(0);
BasicBlock *NewBB = new BasicBlock(TIBB->getName()+DestBB->getName()+"dummy_bb",&F);
new BranchInst(DestBB, NewBB);
BranchInst *NewBr = new BranchInst(DestBB, NewBB, V_dummy);
ReplaceInstWithInst(TI, NewBr);
// the following code, we are trying to change value of PHINODE, and trying to find some examples to solve, but we failed
// Since the DestBB is a...