[PATCH] D156055: [NewGVN][PHIOFOPS] Relax conditions when checking safety of memory accesses

Manuel Brito via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 24 02:24:43 PDT 2023


ManuelJBrito updated this revision to Diff 543428.
ManuelJBrito edited the summary of this revision.
ManuelJBrito added a comment.

We don't need to check that the memPhi is in the same block to deem it unsafe. 
A clobbering memPhi that doesn't strictly dominate the original access implies that there are different versions of memory reaching the load and that using the loaded value between iterations isn't safe.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D156055

Files:
  llvm/lib/Transforms/Scalar/NewGVN.cpp
  llvm/test/Transforms/NewGVN/phi-of-ops-loads.ll
  llvm/test/Transforms/NewGVN/storeoverstore.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D156055.543428.patch
Type: text/x-patch
Size: 9425 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230724/d3f1eae9/attachment.bin>


More information about the llvm-commits mailing list