New Generation Computing

, Volume 16, Issue 1, pp 75–95 | Cite as

On the degeneration of program generators by program composition

  • Robert Glück
  • Andrei Klimov
Article

Abstract

One of the main discoveries in the seventies was that the concept of a generating extension covers a very wide class of apparently different program generators. Program specialization, or partial evaluation, is powerful because it provides uniform techniques for the automatic implementation of generating extensions from ordinary programs. The Futamura projections stand as the cornerstone of the development of program specialization.

This paper takes the idea of the Futamura projections further. Threedegeneration projections are formulated which tell us how to achieve the reverse goal by program composition, namely turning a generating extension into an ordinary program. The fact that program composition can invert the effect of program specialization shows that these projections are dual in a sense. The degeneration projections complete a missing link between programs and generating extensions and allow for novel applications of program transformation.

Keywords

Programming Languages Program Transformation Partial Evaluation Program Specialization Program Composition Metacomputation 

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1).
    Ershov, A. P., “On the Essence of Compilation,” inFormal Description of Programming Concepts (E. J. Neuhold, ed.), North-Holland, pp. 391–420, 1978.Google Scholar
  2. 2).
    Futamura, Y., “Partial Computation of Programs,” inRIMS Symposia on Software Science and Engineering (E. Goto, K. Furukawa R. Nakajima, I. Nakata, and A. Yonezawa, eds.), Springer-Verlag, pp. 1–35, 1983.Google Scholar
  3. 3).
    Bjørner, D., Ershov, A. P., and Jones, N. D. (eds.),Paritial Evaluation and Mixed Computation, North-Holland, 1988.Google Scholar
  4. 4).
    Jones, N. D., Gomard, C. K., and Sestoft, P.,Partial Evaluation and Automatic Program Generation, Prentice-Hall, 1993.Google Scholar
  5. 5).
    Danvy, O., Glück, R., and Thiemann, P. (eds.),Partial Evaluation, volume 1110 of Lecture Notes in Computer Science, Springer-Verlag, 1996.Google Scholar
  6. 6).
    Futamura, Y., “Partial Evaluation of Computing Process—An Approach to a Compiler-Compiler,”Systems, Computers, Controls, 2, 5, pp. 45–50, 1971.Google Scholar
  7. 7).
    Turchin, V. F., “The Concept of a Supercompiler,”Transactions on Programming Languages and Systems, 8, 3, pp. 292–325, 1986.MATHCrossRefMathSciNetGoogle Scholar
  8. 8).
    Wadler, P., “Deforestation: Transforming Programs to Eliminate Trees,”Theoretical Computer Science, 73, pp. 231–248, 1990.MATHCrossRefMathSciNetGoogle Scholar
  9. 9).
    Fegaras, L., Sheard, T., and Zhou, T., “Improving Programs Which Recurse over Multiple Inductive Structures,” inACM SIGPLAN Workshop on Partial Evaluation and Semantics-Based Program Manipulation, Orlando, Florida, pp. 21–32, 1994.Google Scholar
  10. 10).
    Takano, A. and Meijer, E., “Shortcut Deforestation in Calculational Form,” inConference on Functional Programming Languages and Computer Architecture, ACM Press, pp. 306–313, 1995.Google Scholar
  11. 11).
    Turchin, V. F., “Ehkvivalentnye preobrazovanija rekursivnykh funkcij na Refale (Equivalent transformations of recursive functions defined in Refal),” inTeorija Jazykov i Metody Programmirovanija (Proceedings of the Symposium on the Theory of Languages and Programming Methods), pp. 31–42, 1972. [In Russian]Google Scholar
  12. 12).
    Bratman, H., “An Alternate Form of the ‘UNCOL Diagram,’”Communications of the ACM, 4, 3, p. 142, 1961.CrossRefGoogle Scholar
  13. 13).
    Earley, J. and Sturgis, H., “A Formalism for Translator Interactions,”Communications of the ACM, 13, 10, pp. 607–617, 1970.MATHCrossRefGoogle Scholar
  14. 14).
    Glück, R. and Klimov, A. V., “Metasystem Transition Schemes in Computer Science and Mathematics,”World Futures, 45, pp. 213–243, 1995.CrossRefGoogle Scholar
  15. 15).
    Glück, R., “On the Mechanics of Metasystem Hierarchies in Program Transformation,” inLogic Program Synthesis and Transformation, volume 1048 of Lecture Notes in Computer Science (M. Proietti, ed.), Springer-Verlag, pp. 234–251, 1996.Google Scholar
  16. 16).
    Turchin, V. F., “Metacomputation: Metasystem Transitions plus Supercompilation,” inPartial Evaluation, volume 1110 of Lecture Notes in Computer Science (O. Danvy, R. Glück, and P. Thiemann, ed.), Springer-Verlag, pp. 481–509, 1996.Google Scholar
  17. 17).
    Glück, R. and Jørgensen, J., “Efficient Multi-Level Generating Extensions for Program Specialization,” inProgramming Languages: Implementations, Logics and Programs (PLILP’95) (M. Hermenegildo and S. D. Swierstra, eds.),volume 982 of Lecture Notes in Computer Science, Springer-Verlag, pp. 259–278, 1995.Google Scholar
  18. 18).
    Turchin, V. F.,The Phenomenon of Science, Columbia University Press, New York, 1977.Google Scholar
  19. 19).
    Tofte, M.,Compiler Generators, volume 19 of EATCS Monographs on Theoretical Computer Science, Springer-Verlag, 1990.Google Scholar
  20. 20).
    Glück, R., “On the Generation of Specializers,”Journal of Functional Programming, 4, 4, pp. 499–514, 1994.CrossRefGoogle Scholar
  21. 21).
    Bondorf, A., “Automatic Autoprojection of Higher Order Recursive Equations,”Science of Computer Programming, 17, 1–3, pp. 3–34, 1991.MATHCrossRefGoogle Scholar
  22. 22).
    Turchin, V. F., “Program Transformation with Metasystem Transitions,”Journal of Functional Programming, 3, 3, pp. 283–313, 1993.CrossRefGoogle Scholar
  23. 23).
    Abramov, S. M.,Metavychislenija i ikh prilozhenija (Metacomputation and its Applications), Nauka, Moscow, 1995, [In Russian]Google Scholar

Copyright information

© Ohmsha, Ltd. and Springer 1998

Authors and Affiliations

  • Robert Glück
    • 1
  • Andrei Klimov
    • 2
  1. 1.Department of Computer ScienceUniversity of CopenhagenCopenhagenDenmark
  2. 2.Keldysh Institute of Applied MathematicsRussian Academy of SciencesMoscowRussia

Personalised recommendations