Skip to main content
Log in

How to control unfolding when specializing interpreters

  • Regular Papers
  • Published:
New Generation Computing Aims and scope Submit manuscript

Abstract

An interpreter can be viewed as performing two tasks: parsing and execution. Interpreters are specialized by partially evaluating the parsing activity while leaving the execution component as residue. We give a procedure for identifying goals that participate in the parsing process and present rules for unfolding these goals. The unfolding rules are independent of the object-program being compiled and can be generated by a one-time inspection of an interpreter. This makes specializing interpreters a practical technique for compiling programs.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. Ershov, A. P., “On the partial computation principle,”Information Processing Letters, Vol. 6, No. 2, pp. 38–41, April, 1977.

    Article  Google Scholar 

  2. Fujita, H. and Furukawa, K., “A self-applicable partial evaluator and its use in incremental compilation,”New Generation Computing, Vol. 6, Nos. 2-3, pp. 91–118, 1988.

    Article  Google Scholar 

  3. Fuller, D. and Abramsky, S., “Mixed computation of Prolog programs,”New Generation Computing, Vol. 6, Nos. 2-3, pp. 119–142, 1988.

    Article  Google Scholar 

  4. Futamura, Y., “Partial evaluation of computation process—an approach to a compiler-compiler,”Systems, Computers, Controls, 25, pp. 45–50, 1971.

    Google Scholar 

  5. Jones, N. D., Sestoft, P., and Søndergard, H., “An experiment in partial evaluation: The generation of a compiler generator,”Lecture Notes in Computer Science, 202, pp. 124–140, 1985.

    Google Scholar 

  6. Komorowski, H. J., “A Specification of an Abstract Prolog Machine and its Application to Partial Evaluation,”Ph. D. thesis, Linköping Studies in Science and Technology, 1981.

  7. Levi, G. and Sardu, G., “Partial evaluation of metaprograms in a “multiple worlds” logic language,”New Generation Computing, Vol. 6, Nos. 2-3, pp. 227–248, 1988.

    Article  Google Scholar 

  8. Neumann, G.,Metaprogrammeirung und Prolog, Addison-Wesley, 1988.

  9. Pereira, F. and Shieber, S., “Prolog and natural-language analysis,”Technical Report, Lecture Notes #10, Center for the Study of Language and Information, 1987.

  10. Sterling, L. S. and Beer, R. D., “Meta-Interpreters for Expert System Construction,”Journal of Logic Programming, Vol. 6, Nos. 1-2, pp. 163–178, 1989.

    Article  Google Scholar 

  11. Sterling, L. S. and Shapiro, E. Y.,The Art of Prolog, MIT Press, 1986.

  12. Takeuchi, A. and Furukawa, K., “Partial evaluation of Prolog programs and its application to meta programming,” inInformation Processing 86, North-Holland, pp. 415–420, 1986.

Download references

Author information

Authors and Affiliations

Authors

About this article

Cite this article

Lakhotia, A., Sterling, L. How to control unfolding when specializing interpreters. New Gener Comput 8, 61–70 (1990). https://doi.org/10.1007/BF03037513

Download citation

  • Received:

  • Revised:

  • Issue Date:

  • DOI: https://doi.org/10.1007/BF03037513

Keywords

Navigation