forked from OSchip/llvm-project
88e2bac94d
MemorySSAUpdater::getPreviousDefRecursive is a recursive algorithm, for each block, it computes the previous definition for each predecessor, then takes those definitions and combines them. But currently it doesn't remember results which it already computed; this means it can visit the same block multiple times, which adds up to exponential time overall. To fix this, this patch adds a cache. If we computed the result for a block already, we don't need to visit it again because we'll come up with the same result. Well, unless we RAUW a MemoryPHI; in that case, the TrackingVH will be updated automatically. This matches the original source paper for this algorithm. The testcase isn't really a test for the bug, but it adds coverage for the case where tryRemoveTrivialPhi erases an existing PHI node. (It's hard to write a good regression test for a performance issue.) Differential Revision: https://reviews.llvm.org/D44715 llvm-svn: 328577 |
||
---|---|---|
.. | ||
hoist-call.ll | ||
hoist-convergent.ll | ||
hoist-inline.ll | ||
hoist-md.ll | ||
hoist-more-than-two-branches.ll | ||
hoist-mssa.ll | ||
hoist-newgvn.ll | ||
hoist-pr20242.ll | ||
hoist-pr22005.ll | ||
hoist-pr28606.ll | ||
hoist-pr28933.ll | ||
hoist-pr31891.ll | ||
hoist-recursive-geps.ll | ||
hoist-simplify-phi.ll | ||
hoist-unsafe-pr31729.ll | ||
hoist-very-busy.ll | ||
hoist.ll | ||
infinite-loop-direct.ll | ||
infinite-loop-indirect.ll | ||
int_sideeffect.ll | ||
ld_hoist1.ll | ||
ld_hoist_st_sink.ll | ||
pr28626.ll | ||
pr29031.ll | ||
pr29034.ll | ||
pr30216.ll | ||
pr30499.ll | ||
pr35222-hoist-load.ll |