search for: correctextracfgedges

Displaying 8 results from an estimated 8 matches for "correctextracfgedges".

2008 Oct 14
3
[LLVMdev] CFG modifcations and code gen
...e I'm using to do this transformation, which takes 2 & 4 and places them after block 5 is: MachineBasicBlock* newExitPath = findLowestNumSuccBB(root); pHigh->addSuccessor(newExitPath); root->removeSuccessor(newExitPath); root->CorrectExtraCFGEdges(*root->succ_begin(), NULL, false); pHigh->CorrectExtraCFGEdges(*pHigh->succ_begin(), newExitPath, false); newExitPath->moveAfter(pHigh); root->getParent()->RenumberBlocks(); So what am I doing wrong? Thanks, Micah V...
2008 Oct 14
0
[LLVMdev] CFG modifcations and code gen
...his transformation, which takes 2 & 4 and places them after > block 5 is: > MachineBasicBlock* newExitPath = findLowestNumSuccBB(root); > pHigh->addSuccessor(newExitPath); > root->removeSuccessor(newExitPath); > root->CorrectExtraCFGEdges(*root->succ_begin(), > NULL, false); > pHigh->CorrectExtraCFGEdges(*pHigh->succ_begin(), > newExitPath, false); > newExitPath->moveAfter(pHigh); > root->getParent()->RenumberBlocks(); > > So what am I doing w...
2008 Oct 14
2
[LLVMdev] CFG modifcations and code gen
...#39;m using to do this transformation, which takes 2 & 4 and places them after block 5 is: MachineBasicBlock* newExitPath = findLowestNumSuccBB(root); pHigh->addSuccessor(newExitPath); root->removeSuccessor(newExitPath); root->CorrectExtraCFGEdges(*root->succ_begin(), NULL, false); pHigh->CorrectExtraCFGEdges(*pHigh->succ_begin(), newExitPath, false); newExitPath->moveAfter(pHigh); root->getParent()->RenumberBlocks(); So what am I doing wrong? Thanks, Micah Villmo...
2013 Apr 10
3
[LLVMdev] If Conversion and predicated returns
...xtraEdges - Remove true / false edges if either / both are no longer /// successors. void IfConverter::RemoveExtraEdges(BBInfo &BBI) { MachineBasicBlock *TBB = NULL, *FBB = NULL; SmallVector<MachineOperand, 4> Cond; if (!TII->AnalyzeBranch(*BBI.BB, TBB, FBB, Cond)) BBI.BB->CorrectExtraCFGEdges(TBB, FBB, !Cond.empty()); } and I think that this function is supposed to clean up the successors of BB#1 after merging. The problem is that the PPC implementation of AnalyzeBranch does not understand returns (conditional or otherwise). I'm not sure what the best way of dealing with this is. S...
2008 Sep 20
0
[LLVMdev] Disappearing Machine Basic Blocks (for new instruction)
For anyone to have any shot of answering your question, you need to provide more information. To start, please figure out which pass deleted the block, what does the machine function looks like before and after. Evan On Sep 19, 2008, at 4:14 PM, Edward Lee wrote: > I have a new instruction that takes 2 labels, and in SelectionDAGISel, > I have it doing
2009 Aug 06
0
[LLVMdev] code-altering Passes for llc
On Aug 6, 2009, at 5:45 AM, Artjom Kochtchi wrote: > So I was searching for a possibility to include an additional > (Machine)BasicBlock (or rather a MachineFunction?) somewhere in the > program > that contains the program termination and that I can jump to on check > failure. Can't I do that during a Pass in llc? If you just have a magic block of instructions you want to
2009 Aug 06
2
[LLVMdev] code-altering Passes for llc
Kenneth Uildriks wrote: > > Does the error function *have* to be auto-generated in your pass? > Perhaps the original code should use invokes, and your pass insert the > error check with a jne to the "unwind" block. > If I understand correctly, unwind is some kind of exception handling in LLVM IR? I'm not sure if this is the right thing. First, I include runtime
2008 Sep 19
2
[LLVMdev] Disappearing Machine Basic Blocks (for new instruction)
I have a new instruction that takes 2 labels, and in SelectionDAGISel, I have it doing "CurMBB->addSuccessor()" for both machine blocks. The DAG node it creates also takes both blocks as SDOperands. When I lower to x86, the not-fallthrough block disappears. If I run llc with --fast, the blocks stay around, so it must be an optimization pass of some sort that doesn't realize my