Deleted Added
sdiff udiff text old ( 198396 ) new ( 200581 )
full compact
1//===- SSAUpdater.cpp - Unstructured SSA Update Tool ----------------------===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//

--- 281 unchanged lines hidden (view full) ---

290 OldVal->replaceAllUsesWith(SingularValue);
291 else
292 OldVal->replaceAllUsesWith(UndefValue::get(InsertedVal->getType()));
293 OldVal->eraseFromParent();
294 } else {
295 InsertedVal = SingularValue;
296 }
297
298 // Drop the entries we added in IncomingPredInfo to restore the stack.
299 IncomingPredInfo.erase(IncomingPredInfo.begin()+FirstPredInfoEntry,
300 IncomingPredInfo.end());
301 return InsertedVal;
302 }
303
304 // Otherwise, we do need a PHI: insert one now if we don't already have one.
305 if (InsertedVal == 0)
306 InsertedVal = PHINode::Create(PrototypeValue->getType(),
307 PrototypeValue->getName(), &BB->front());
308
309 PHINode *InsertedPHI = cast<PHINode>(InsertedVal);

--- 27 unchanged lines hidden ---