Practical Techniques to Augment Dependence Analysis in the Presence of Symbolic Terms
This work was also published as a Rice University thesis/dissertation: http://hdl.handle.net/1911/19163
Dependence analysis is an indispensable tool in the automatic vectorization and parallelization of sequential programs, but performing symbolic dependence analysis can be costly and may fail to resolve many unknown terms. In this thesis, we explore ways to overcome the problems symbolic terms create for dependence analysis. We investigate three approaches to enhancing code optimization in the presence of symbolic terms: run-time testing, inserting user assertions, and compiling the program together with its input. Breaking conditions are created by the dependence analyzer when the presence of symbolic terms make it impossible to prove or disprove independence. If a breaking condition is satisfied at run-time, then optimized code can be executed. We show that the use of breaking conditions was responsible for more than one-fifth of all dependences eliminated in our test suite. Index array assertions are user-inserted directives describing special properties of the index arrays used in a program. We show that such directives can eliminate additional dependences by providing information that cannot be obtained using dependence analysis. Partial evaluation can be used to inspect a program's input file and disseminate the actual values of symbolic variables before dependence analysis is done. We show that partial evaluation assists dependence analysis by reducing the number of unknown symbolic terms. Algorithms for these techniques, developed and implemented in a parallelizing compiler, are presented, along with the results of several empirical studies.