careful about referencing values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134537
91177308-0d34-0410-b5e6-
96231b3b80d8
namespace {
class IndVarSimplify : public LoopPass {
- typedef DenseMap<const SCEV *, PHINode *> ExprToIVMapTy;
+ typedef DenseMap< const SCEV *, AssertingVH<PHINode> > ExprToIVMapTy;
IVUsers *IU;
LoopInfo *LI;
// can be deleted in the loop below, causing the AssertingVH in the cache to
// trigger.
Rewriter.clear();
+ ExprToIVMap.clear();
// Now that we're done iterating through lists, clean up any instructions
// which are now dead.