[PATCH] D72148: [DSE] Support traversing MemoryPhis.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 3 06:17:03 PST 2020


fhahn created this revision.
fhahn added reviewers: dmgreen, rnk, efriedma, bryant, asbirlea.
Herald added subscribers: george.burgess.iv, hiraditya.
Herald added a project: LLVM.

For MemoryPhis, we have to avoid that the MemoryPhi may be executed
before before the access we are currently looking at.

To do this we do a post-order numbering of the basic blocks in the
function and bail out once we reach a MemoryPhi with a larger (or equal)
post-order block number than the current MemoryAccess.

This changes the order in which we visit stores for elimination.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D72148

Files:
  llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp
  llvm/test/Transforms/DeadStoreElimination/MSSA/memoryssa-debugcounter.ll
  llvm/test/Transforms/DeadStoreElimination/MSSA/multiblock-loops.ll
  llvm/test/Transforms/DeadStoreElimination/MSSA/multiblock-memoryphis.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D72148.236042.patch
Type: text/x-patch
Size: 10322 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200103/24ccee42/attachment.bin>


More information about the llvm-commits mailing list