[llvm] r367160 - Revert [IPSCCP] Add assertion to surface cases where we zap returns with overdefined users.

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 26 15:14:08 PDT 2019


Author: fhahn
Date: Fri Jul 26 15:14:08 2019
New Revision: 367160

URL: http://llvm.org/viewvc/llvm-project?rev=367160&view=rev
Log:
Revert [IPSCCP] Add assertion to surface cases where we zap returns with overdefined users.

This reverts r366998 (git commit 5354c83ece00690b4dbfa47925f8f5a8f33f1d9e)

This breaks a linux kernel build and we have reproducer to investigate.

Modified:
    llvm/trunk/lib/Transforms/Scalar/SCCP.cpp

Modified: llvm/trunk/lib/Transforms/Scalar/SCCP.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/SCCP.cpp?rev=367160&r1=367159&r2=367160&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/SCCP.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/SCCP.cpp Fri Jul 26 15:14:08 2019
@@ -1924,21 +1924,6 @@ static void findReturnsToZap(Function &F
     return;
   }
 
-  assert(
-      all_of(F.users(),
-             [&Solver](User *U) {
-               if (isa<Instruction>(U) &&
-                   !Solver.isBlockExecutable(cast<Instruction>(U)->getParent()))
-                 return false;
-               if (U->getType()->isStructTy()) {
-                 return all_of(
-                     Solver.getStructLatticeValueFor(U),
-                     [](const LatticeVal &LV) { return !LV.isOverdefined(); });
-               }
-               return !Solver.getLatticeValueFor(U).isOverdefined();
-             }) &&
-      "We can only zap functions where all live users have a concrete value");
-
   for (BasicBlock &BB : F) {
     if (CallInst *CI = BB.getTerminatingMustTailCall()) {
       LLVM_DEBUG(dbgs() << "Can't zap return of the block due to present "




More information about the llvm-commits mailing list