mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-12 13:38:21 +00:00
remove use of BasicBlock::getNext
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36205 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -155,7 +155,8 @@ BasicBlock* LowerSwitch::switchConvert(CaseItr Begin, CaseItr End,
|
||||
// left branch if it is and right branch if not.
|
||||
Function* F = OrigBlock->getParent();
|
||||
BasicBlock* NewNode = new BasicBlock("NodeBlock");
|
||||
F->getBasicBlockList().insert(OrigBlock->getNext(), NewNode);
|
||||
Function::iterator FI = OrigBlock;
|
||||
F->getBasicBlockList().insert(++FI, NewNode);
|
||||
|
||||
ICmpInst* Comp = new ICmpInst(ICmpInst::ICMP_SLT, Val, Pivot.Low, "Pivot");
|
||||
NewNode->getInstList().push_back(Comp);
|
||||
@ -175,7 +176,8 @@ BasicBlock* LowerSwitch::newLeafBlock(CaseRange& Leaf, Value* Val,
|
||||
{
|
||||
Function* F = OrigBlock->getParent();
|
||||
BasicBlock* NewLeaf = new BasicBlock("LeafBlock");
|
||||
F->getBasicBlockList().insert(OrigBlock->getNext(), NewLeaf);
|
||||
Function::iterator FI = OrigBlock;
|
||||
F->getBasicBlockList().insert(++FI, NewLeaf);
|
||||
|
||||
// Emit comparison
|
||||
ICmpInst* Comp = NULL;
|
||||
|
Reference in New Issue
Block a user