AS imple, Fast Dominance Algorithm
AS imple, Fast Dominance Algorithm
复制标题
ASimple,快速优势算法
DOI:
--
复制
发表时间:
1999
期刊:
影响因子:
--
通讯作者:
K. Kennedy
中科院分区:
文献类型:
--
作者:
K. Cooper;Timothy J. Harvey;K. Kennedy
Th ep roblem of finding the dominators in a control-flow graph has a long history in the literature. The original algorithms suffered from a large asymptotic complexity but were easy to understand. Subsequent work improved the time bound, but generally sacrificed both simplicity and ease of implementation. This paper returns to a simple formulation of dominance as a global data-flow problem. Some insights into the natur eo f dominance lead to an implementation of an O(N 2 )a lgorithm that runs faster, in practice, than the classic Lengauer-Tarjan algorithm, which has a timebound of O(E ∗ log(N )). We compare the algorithm to Lengauer-Tarjan because it is the best known and most widely used of the fast algorithms for dominance. Working from the same implementatio ni nsights, we also rederive (from earlier work on control dependence by Ferrante, et al. )a method for calculating dominance frontiers that we show is faster than the original algorithm by Cytron, et al. The aim of this paper is not to present a new algorithm, but, rather, to make an argument based on empirical evidence that algorithms with discouraging asymptotic complexities can be faster in practice than those more commonly employed. We show that, in some cases, careful engineering of simple algorithms can overcome theoretical advantages, even when problems grow beyond realistic sizes. Further, we argue that the algorithms presented herein are intuitive and easily implemented, making them excellent teaching tools.