Comprehensive path-sensitive data-flow analysis
- 6 April 2008
- conference paper
- Published by Association for Computing Machinery (ACM)
Abstract
Data-flow analysis is an integral part of any aggressive optimizing compiler. We propose a framework for improving the precision of data-flow analysis in the presence of complex control-flow. We initially perform data-flow analysis to determine those control-flow merges which cause the loss in data-flow analysis precision. The control-flow graph of the program is then restructured such that performing data-flow analysis on the resulting restructured graph gives more precise results. The proposed framework is both simple, involving the familiar notion of product automata, and also general, since it is applicable to any forward data-flow analysis. Apart from proving that our restructuring process is correct, we also show that restructuring is effective in that it necessarily leads to more optimization opportunities. Furthermore, the framework handles the trade-off between the increase in data-flow precision and the code size increase inherent in the restructuring. We show that determining an optimal restructuring is NP-hard, and propose and evaluate a greedy strategy. The framework has been implemented in the Scale research compiler, and instantiated for the specific problem of Constant Propagation. On the SPECINT 2000 benchmark suite we observe an average speedup of 4% in the running times over Wegman-Zadeck conditional constant propagation algorithm and 2% over a purely path profile guided approach.Keywords
This publication has 11 references indexed in Scilit:
- A framework for unrestricted whole-program optimizationPublished by Association for Computing Machinery (ACM) ,2006
- Joining dataflow with predicatesPublished by Association for Computing Machinery (ACM) ,2005
- Improving the static analysis of loops by dynamic partitioning techniquesPublished by Institute of Electrical and Electronics Engineers (IEEE) ,2004
- ESPPublished by Association for Computing Machinery (ACM) ,2002
- Improving data-flow analysis with path profilesPublished by Association for Computing Machinery (ACM) ,1998
- Complete removal of redundant expressionsPublished by Association for Computing Machinery (ACM) ,1998
- Path-sensitive value-flow analysisPublished by Association for Computing Machinery (ACM) ,1998
- Constant propagation with conditional branchesACM Transactions on Programming Languages and Systems, 1991
- Qualified Data Flow ProblemsIEEE Transactions on Software Engineering, 1981
- Symbolic evaluation and the global value graphPublished by Association for Computing Machinery (ACM) ,1977