skip to main content
10.1145/1014007.1014019acmconferencesArticle/Chapter ViewAbstractPublication PagespepmConference Proceedingsconference-collections
Article

Imperative program optimization by partial evaluation

Published:24 August 2004Publication History

ABSTRACT

We implement strength reduction and loop-invariant code motion by specializing instrumented interpreters; we define a novel program transformation that uses bisimulation to identify and remove code duplication in residual programs; and we discover that some simple classical optimizations, notably constant-propagation, seemingly do not lend themselves to implementation by specialization of instrumented interpreters.

References

  1. N. Benton. Simple relational correctness proofs for static analyses and program transformations. In Proceedings of the 31st ACM Symposium On Principles of Programming Languages (POPL04), 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. R. M. Burstall and J. Darlington. A transformation system for developing recursive programs. Journal of the ACM, 24(1):44--67, 1977. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. P. J. Downey, R. Sethi, and R. E. Tarjan. Variations on the common subexpression problem. Journal of the ACM, 27(4):758--771, 1980. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. R. Glück and J. Jørgensen. Generating optimizing specializers. In IEEE International Conference On Computer Languages, pages 183--194. IEEE Computer Society Press, 1994.Google ScholarGoogle ScholarCross RefCross Ref
  5. R. Glück and J. Jørgensen. Generating transformers for deforestation and supercompilation. In B. Le Charlier, editor, Static Analysis, volume 864 of Lecture Notes in Computer Science, pages 432--448. Springer-Verlag, 1994.Google ScholarGoogle Scholar
  6. C. K. Gomard and N. D. Jones. Compiler generation by partial evaluation: a case study. Structured Programming, 12:123--144, 1991.Google ScholarGoogle Scholar
  7. N. D. Jones. Transformation by interpreter specialisation. Science of Computer Programming, pages 1--40, 2004. accepted for publication. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. N. D. Jones, C. K. Gomard, and P. Sestoft. Partial Evaluation and Automatic Program Generation. Prentice Hall International, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. D. Lacey, N. D. Jones, E. Van Wyk, and C. C. Frederiksen. Proving correctness of compiler optimizations by temporal logic. In Proceedings of the 29Th Annual ACM Symposium On Principles of Programming Languages (POPL02), pages 283--294. ACM Press, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. S. Lerner, T. Millstein, and C. Chambers. Automatically proving the correctness of compiler optimizations. In ACM SIGPLAN Conference On Programming Language Design and Implementation (PLDI 2003), pages 220--231. ACM Press, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. R. Milner. A Calculus of Communicating Systems, volume~92 of Lecture Notes in Computer Science. Springer Verlag, 1980. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. S. S. Muchnick. Advanced Compiler Design & Implementation. Morgan Kaufmann Publishers, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. R. Paige and R. E. Tarjan. Three partition refinement algorithms. SIAM Journal On Computing, 16(6):973--989, Dec. 1987. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. M. Sperber and P. Thiemann. Realistic compilation by partial evaluation. In ACM SIGPLAN '96 Conference On Programming Language Design and Implementation, Philadelphia, Pennsylvania, May 1996 (SIGPLAN Notices, Vol. 31, No. 5), pages 206--214. New York: ACM, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. S. Thibault, C. Consel, J. L. Lawall, R. Marlet, and G. Muller. Static and dynamic program compilation by interpreter specialization. Higher-Order and Symbolic Computation, 13(3):161--178, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Imperative program optimization by partial evaluation

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in
      • Published in

        cover image ACM Conferences
        PEPM '04: Proceedings of the 2004 ACM SIGPLAN symposium on Partial evaluation and semantics-based program manipulation
        August 2004
        212 pages
        ISBN:1581138350
        DOI:10.1145/1014007

        Copyright © 2004 ACM

        Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 24 August 2004

        Permissions

        Request permissions about this article.

        Request Permissions

        Check for updates

        Qualifiers

        • Article

        Acceptance Rates

        Overall Acceptance Rate66of120submissions,55%

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader