Fix PR24469 resulting from r245025 and re-enable dead store elimination across basicb...
authorKarthik Bhat <kv.bhat@samsung.com>
Mon, 17 Aug 2015 05:51:39 +0000 (05:51 +0000)
committerKarthik Bhat <kv.bhat@samsung.com>
Mon, 17 Aug 2015 05:51:39 +0000 (05:51 +0000)
commit75f2d3768621e77427ff754a28d101fc6cecbf56
treec92750bb188438af4e5572da6c5bacf655a19d38
parenta3711bed81b3be66dc9892c31311d0b2053a599d
Fix PR24469 resulting from r245025 and re-enable dead store elimination across basicblocks.
PR24469 resulted because DeleteDeadInstruction in handleNonLocalStoreDeletion was
deleting the next basic block iterator. Fixed the same by resetting the basic block iterator
post call to DeleteDeadInstruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@245195 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/DeadStoreElimination.cpp
test/Transforms/DeadStoreElimination/cross_block_dse.ll [new file with mode: 0644]
test/Transforms/DeadStoreElimination/cross_block_dse_loop.ll [new file with mode: 0644]