mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-14 14:24:05 +00:00
(Almost) always call reserveOperandSpace() on newly created PHINodes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128535 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -142,6 +142,7 @@ static void CreatePHIsForSplitLoopExit(SmallVectorImpl<BasicBlock *> &Preds,
|
||||
// Otherwise a new PHI is needed. Create one and populate it.
|
||||
PHINode *NewPN = PHINode::Create(PN->getType(), "split",
|
||||
SplitBB->getTerminator());
|
||||
NewPN->reserveOperandSpace(Preds.size());
|
||||
for (unsigned i = 0, e = Preds.size(); i != e; ++i)
|
||||
NewPN->addIncoming(V, Preds[i]);
|
||||
// Update the original PHI.
|
||||
|
Reference in New Issue
Block a user