[PATCH] D11143: [RFC] Cross Block DSE
Karthik Bhat
kv.bhat at samsung.com
Mon Jul 13 06:55:14 PDT 2015
karthikthecool created this revision.
karthikthecool added a reviewer: hfinkel.
karthikthecool added a subscriber: llvm-commits.
Hi All,
I would like to propose a RFC on Cross Block Dead Store Elimination.
Cross Block Dead Store elimination implemented in this patch works as follows-
1) When a Store with non local memory dependency we call "handleNonLocalStoreDeletion".
2) In handleNonLocalStoreDeletion we traverse the predecessor blocks of the store instruction till we encounter post domination frontier and try to find a candidate store for deletion.
3) getStoreCandidates finds out if we have a candidate store for deletion which in any of the predecessor block.
4) If we find a candidate store we then see that the store is not used by any instruction in any of the path from the current block till block were the overwriting store is present.
5) We call DeleteDeadInstruction for the candidate store instruction if it is safe to remove the store.
No Regressions were found in make check-all and LLVM LNT test suites.
Please let me know your valuable option on the patch.
Thanks and Regards
Karthik Bhat
http://reviews.llvm.org/D11143
Files:
include/llvm/Analysis/PostDominators.h
include/llvm/InitializePasses.h
include/llvm/LinkAllPasses.h
lib/Analysis/Analysis.cpp
lib/Analysis/PostDominators.cpp
lib/Transforms/Scalar/DeadStoreElimination.cpp
test/Transforms/DeadStoreElimination/cross_block_dse.ll
test/Transforms/DeadStoreElimination/cross_block_dse_loop.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D11143.29560.patch
Type: text/x-patch
Size: 21928 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150713/31fa0021/attachment.bin>
More information about the llvm-commits
mailing list