DeadCodeElimination: rewrite to be faster
authorFiona Glaser <escha@apple.com>
Wed, 30 Sep 2015 17:49:49 +0000 (17:49 +0000)
committerFiona Glaser <escha@apple.com>
Wed, 30 Sep 2015 17:49:49 +0000 (17:49 +0000)
commit07457d5339f4f702c1f0bf953964892c8e554f5e
tree797565920e3771cf85989b788a2f59f9117f95a9
parentaf57daecbb8d5983b75f1ba4aed3a25812a9d760
DeadCodeElimination: rewrite to be faster

Same strategy as simplifyInstructionsInBlock. ~1/3 less time
on my test suite. This pass doesn't have many in-tree users,
but getting rid of an O(N^2) worst case and making it cleaner
should at least make it a viable alternative to ADCE, since
it's now consistently somewhat faster.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@248927 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/DCE.cpp