Unfold/fold transformations and loop optimization of logic programs

Research output: Chapter in Book/Report/Conference proceedingConference contribution

17 Scopus citations

Abstract

Programs typically spend much of their execution time in loops. This makes the generation of efficient code for loops essential for good performance. Loop optimization of logic programming languages is complicated by the fact that such languages lack the iterative constructs of traditional languages, and instead use recursion to express loops. In this paper, we examine the application of unfold/fold transformations to three kinds of loop optimization for logic programming languages: recursion removal, loop fusion and code motion out of loops. We describe simple unfold/fold transformation sequences for these optimizations that can be automated relatively easily. In the process, we show that the properties of unification and logical variables can sometimes be used to generalize, from traditional languages, the conditions under which these optimizations may be carried out. Our experience suggests that such source-level transformations may he used as an effective tool for the optimization of logic programs.

Original languageEnglish (US)
Title of host publicationProceedings of the ACM SIGPLAN 1988 Conference on Programming Language Design and Implementation, PLDI 1988
EditorsR.L. Wexelblat
PublisherAssociation for Computing Machinery
Pages297-307
Number of pages11
ISBN (Electronic)0897912691
DOIs
StatePublished - Jun 1 1988
EventACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 1988 - Atlanta, United States
Duration: Jun 20 1988Jun 24 1988

Publication series

NameProceedings of the ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI)
Volume20-24-June-1988

Other

OtherACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 1988
CountryUnited States
CityAtlanta
Period6/20/886/24/88

ASJC Scopus subject areas

  • Software

Fingerprint Dive into the research topics of 'Unfold/fold transformations and loop optimization of logic programs'. Together they form a unique fingerprint.

  • Cite this

    Debray, S. K. (1988). Unfold/fold transformations and loop optimization of logic programs. In R. L. Wexelblat (Ed.), Proceedings of the ACM SIGPLAN 1988 Conference on Programming Language Design and Implementation, PLDI 1988 (pp. 297-307). (Proceedings of the ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI); Vol. 20-24-June-1988). Association for Computing Machinery. https://doi.org/10.1145/53990.54020