Abstract
Partial redundancy elimination (PRE) is one of the most important and widespread optimizations in compilers. However, current PRE-techniques are inadequate to handle predicated code, i.e., programs where instructions are guarded by a 1-bit register that dynamically controls whether the effect of an instruction should be committed or nullified. In fact, to exclude corrupting the semantics they must be overly conservative making them close to useless. Since predicated code will be more and more common with the advent of the IA-64 architecture, we present here a family of PRE-algorithms tailored for predicated code. Conceptually, the core element of this family can be considered the counterpart of busy code motion of [17]. It can easily be tuned by two orthogonal means. First, by adjusting the power of a preprocess feeding it by information on predication. Second, by relaxing or strengthening the constraints on synthesizing predicates controlling the movability of computations. Together with extensions towards lazy code motion, this results in a family of PRE-algorithms spanning a range from tamed to quite aggressive algorithms, which is illustrated by various meaningful examples.
Part oft his work was done while the second author was working at CNRS/PRiSM Laboratory, University of Versailles, 78035 Versailles, France.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Allen, J.R., Kennedy, K., Porterfield, C., Warren, J.: Conversion of control dependence to data dependence. In: Conf. Rec. 10th Symp. on Principles of Prog. Lang (POPL 1983), pp. 177–189. ACM, NY (1983)
Bodík, R., Anik, S.: Path-sensitive value-flow analysis. In: Conf. Rec. 25th Symp. on Principles of Prog. Lang (POPL 1998), pp. 237–251. ACM, NY (1998)
Briggs, P., Cooper, K.D.: Effective partial redundancy elimination. In: Proc. ACM SIGPLAN Conf. Prog. Lang. Design and Impl (PLDI 1994). ACM SIGPLAN Not., vol. 29(6), pp. 159–170 (1994)
Intel Corp. IA-64 Application Developers Architecture Guide (May 1999)
Dhamdhere, D.M., Rosen, B.K., Zadeck, F.K.: How to analyze large programs efficiently and informatively. In: Proc. ACM SIGPLAN Conf. Prog. Lang. Design and Impl (PLDI 1992), ACM SIGPLAN Not., vol. 27, pp. 212–223 (1992)
Dulong, C.: The IA-64 architecture at work. IEEE Computer 31(7), 24–32 (1998)
Eichenberger, A.E., Davidson, E.S.: Register allocation for predicated code. In: Proc. 28th Int. Symp. on Microarchitecture (MICRO-28), vol. 26, pp. 180–191 (1995)
Fang, J.Z.: Compiler algorithms on If-conversion, speculative predicate assignment and predicated code optimizations. In: Sehr, D., Banerjee, U., Gelernter, D., Nicolau, A., Padua, D.A. (eds.) LCPC 1996. LNCS, vol. 1239, pp. 135–153. Springer, Heidelberg (1997)
Gillies, D.M., Ju, D.C.R., Johnson, R., Schlansker, M.: Global predicate analysis and its application to register allocation. In: Proc. 29th Int. Symp. on Microarchitecture (MICRO-29), vol. 27 (1996)
Gupta, R., Berson, D., Fang, J.Z.: Path profile guided partial dead code elimination using predication. In: Proc. 5th IEEE Int. Conf. on Parallel Arch. and Comp. Techniques (PACT 1997), pp. 102–115. IEEE Comp. Soc, CA (1997)
Hecht, M.S.: Flow Analysis of Computer Programs. Elsevier, North-Holland (1977)
Holley, L.H., Rosen, B.K.: Qualified data flow problems. IEEE Trans. Softw. Eng. 1(SE-7), 60–78 (1981)
Johnson, R., Schlansker, M.: Analysis techniques for predicated code. In: Proc. 29th Int. Symp. on Microarchitecture (MICRO-29), vol. 27, pp. 100–113 (1996)
Knoop, J., Collard, J.-F., Ju, R.D.: Partial redundancy elimination on predicated code: Motivation and algorithm. Technical Report 731/2000, Fachbereich Informatik, Universität Dortmund, Germany (2000)
Knoop, J., Rüthing, O.: Optimization under the perspective of soundness, completeness, and reusability. In: Olderog, E.-R., Steffen, B. (eds.) Correct System Design. LNCS, vol. 1710, pp. 288–315. Springer, Heidelberg (1999) (invited contirbution)
Knoop, J., Rüthing, O., Steffen, B.: Lazy code motion. In: Proc. ACM SIGPLAN Conf. Prog. Lang. Design and Impl (PLDI 1992). ACM SIGPLAN Not., vol. 27(7), pp. 224–234 (1992)
Knoop, J., Rüthing, O., Steffen, B.: Optimal code motion: Theory and practice. ACM Trans. Prog. Lang. Syst. 16, 1117–1155 (1994)
Knoop, J., Rüthing, O., Steffen, B.: Partial dead code elimination. In: Proc. ACM SIGPLAN Conf. Prog. Lang. Design and Impl (PLDI 1994). ACM SIGPLAN Not., vol. 29(6), p. 147–158 (1994)
Knoop, J., Rüthing, O., Steffen, B.: The power of assignment motion. In: Proc. ACM SIGPLAN Conf. Prog. Lang. Design and Impl (PLDI 1995). ACM SIGPLAN Not., vol. 30(6), pp. 233–245 (1995)
Knoop, J., Rüthing, O., Steffen, B.: Code motion and code placement: Just synomyms? In: Hankin, C. (ed.) ESOP 1998. LNCS, vol. 1381, pp. 154–169. Springer, Heidelberg (1998)
Mahlke, S.A., Lin, D.C., Chen, W.Y., Hank, R.E., Bringmann, R.A.: Effective compiler support for predicated execution using the hyperblock. In: Proc. 25th Int. Symp. on Microarchitecture (MICRO-25), vol. 23(1&2), pp. 45–54 (1992)
Morel, E., Renvoise, C.: Global optimization by suppression of partial redundancies. Comm. ACM 22(2), 96–103 (1979)
Muchnick, S.S.: Advanced Compiler Design and Implementation. Morgan Kaufmann, San Francisco (1997)
Rosen, B.K., Wegman, M.N., Zadeck, F.K.: Global value numbers and redundant computations. In: Conf. Rec. 15th Symp. Principles of Prog. Lang (POPL 1988), pp. 2–27. ACM, NY (1988)
Rüthing, O., Knoop, J., Steffen, B.: Sparse code motion. In: Conf. Rec. 27th Symp. Principles of Prog. Lang (POPL 2000), pp. 170–183. ACM, NY (2000)
Steffen, B., Knoop, J., Rüthing, O.: The value flow graph: A program representation for optimal program transformations. In: Jones, N.D. (ed.) ESOP 1990. LNCS, vol. 432, pp. 389–405. Springer, Heidelberg (1990)
Warter, N.J., Mahlke, S.A., Hwu, W.-M., Rau, B.R.: Reverse if-conversion. In: Proc. ACM SIGPLAN Conf. Prog. Lang. Design and Impl (PLDI 1993). ACM SIGPLAN Not., vol. 28(6), pp. 290–299 (1993)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2000 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Knoop, J., Collard, JF., Ju, R.Dc. (2000). Partial Redundancy Elimination on Predicated Code. In: Palsberg, J. (eds) Static Analysis. SAS 2000. Lecture Notes in Computer Science, vol 1824. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-45099-3_14
Download citation
DOI: https://doi.org/10.1007/978-3-540-45099-3_14
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-67668-3
Online ISBN: 978-3-540-45099-3
eBook Packages: Springer Book Archive