[PATCH] D71974: [Attributor][WIP] Connect AAIsDead with AAUndefinedBehavior

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 5 15:53:46 PST 2020


jdoerfert added a comment.

Tests?



================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:2285
     for (Instruction *I : KnownUBInsts)
-      A.changeToUnreachableAfterManifest(I);
+      //A.changeToUnreachableAfterManifest(I);
     return ChangeStatus::CHANGED;
----------------
What is happening here? Leftover?


================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:2322
 private:
+  MustBeExecutedContextExplorer *Explorer;
   /// A set of all the (live) instructions that are assumed to _not_ cause UB.
----------------
I would prefer if we pass the Explorer (or the Attributor) instead of caching it.


================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:3418
+        const BasicBlock *BB = AliveSuccessor->getParent();
+        AssumedLiveBlocks.erase(BB);
+      } else {
----------------
I don't think retroactively removing blocks here is a good idea. Once assumed live it should stay that way.


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

https://reviews.llvm.org/D71974





More information about the llvm-commits mailing list