[PATCH] D91661: Revert of D49126 [PredicateInfo] Use custom mangling to support ssa_copy with unnamed types.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 14 15:08:34 PDT 2021


fhahn accepted this revision.
fhahn added a comment.
This revision is now accepted and ready to land.

LGTM, thanks!



================
Comment at: llvm/lib/Transforms/Utils/PredicateInfo.cpp:764
 
-// Remove all declarations we created . The PredicateInfo consumers are
-// responsible for remove the ssa_copy calls created.
-PredicateInfo::~PredicateInfo() {
-  // Collect function pointers in set first, as SmallSet uses a SmallVector
-  // internally and we have to remove the asserting value handles first.
-  SmallPtrSet<Function *, 20> FunctionPtrs;
-  for (auto &F : CreatedDeclarations)
-    FunctionPtrs.insert(&*F);
-  CreatedDeclarations.clear();
-
-  for (Function *F : FunctionPtrs) {
-    assert(F->user_begin() == F->user_end() &&
-           "PredicateInfo consumer did not remove all SSA copies.");
-    F->eraseFromParent();
-  }
-}
+PredicateInfo::~PredicateInfo() {}
 
----------------
nit: move to the header?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D91661/new/

https://reviews.llvm.org/D91661



More information about the llvm-commits mailing list