// Insert a load in place of the PHI and replace all uses.
BasicBlock::iterator InsertPt = P;
- for (; isa<PHINode>(InsertPt) || InsertPt->isEHPad(); ++InsertPt)
+ for (; isa<PHINode>(InsertPt) || isa<LandingPadInst>(InsertPt); ++InsertPt)
/* empty */; // Don't insert before PHI nodes or landingpad instrs.
Value *V = new LoadInst(Slot, P->getName()+".reload", InsertPt);