Automatic bottom-up analysis and transformation of logic programs

  • Wamberto W. Vasconcelos
  • Marcelo A. T. Aragão
  • Norbert E. Fuchs
Logic Programming, Temporal Reasoning and Belief Functions
Part of the Lecture Notes in Computer Science book series (LNCS, volume 1159)


The comparatively small size and clean declarative semantics of logic programs hide performance issues that must be accounted for if the programs are to be executed using the currently available technology. Proposals have been made to tackle these computational issues by analysing a program and trying to optimise its code. We introduce a bottom-up method for analysing logic programs. The method incrementally builds self-contained subtheories of the initial program, starting from facts and then picking up more complex clauses that depend on simpler, previously analysed constructs. A transformation system is then applied to these subtheories yielding more efficient subprograms. Eventually a subtheory that encompasses the full initial program is obtained.


Logic programming automatic program transformation 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. [FF92]
    N. E. Fuchs and M. P. J Fromherz. Schema-Based Transformations of Logic Programs. In Proceedings of the International Workshop on Logic Program Synthesis and Transformation (LoPSTr'92). Springer-Verlag, 1992.Google Scholar
  2. [Gal95]
    J. P. Gallagher. A Bottom-Up Analysis Toolkit. Technical report, Dept. Comp. Sci., Univ. of Bristol, 1995. Invited talk given at WAILL (Workshop on Abstract Interpretation of Logic Languages), Israel.Google Scholar
  3. [HL78]
    G. Huet and B. Lang. Proving and Applying Program Transformations Expressed with Second-Order Patterns. Acta Informatica, 11:31–55, 1978.Google Scholar
  4. [LS90]
    A. Lakhotia and L. Sterling. How to Control Unfolding when Specialising Interpreters. In L. Sterling, editor, The Practice of Prolog. MIT Press, 1990.Google Scholar
  5. [PP92]
    M. Proietti and A. Pettorossi. Best-first Strategies for Incremental Transformations of Logic Programs. In Proceedings of the Second International Workshop on Logic Program Synthesis and Transformation (LoPSTr'92), 1992.Google Scholar
  6. [PP94]
    M. Proietti and A. Pettorossi. Transformations of Logic Programs: Foundations and Techniques. Journal of Logic Programming, 19, 20:261–320, 1994.Google Scholar
  7. [Rob91]
    D. Robertson. A Simple Prolog Techniques Editor for Novice Users. In 3rd Annual Conference on Logic Programming, Edinburgh, Scotland, April 1991. Springer-Verlag.Google Scholar
  8. [VAa96]
    W. W. Vasconcelos and M. T. Aragão. Proving Schema-Based Transformations for Logic Programs. Extended Abstract, 1996. Available from authors.Google Scholar
  9. [VF95]
    W. W. Vasconcelos and N. E. Fuchs. Opportunistic Logic Program Analysis and Optimisation: Enhanced Schema-Based Transformations for Logic Programs and their Usage in an Opportunistic Framework for Program Analysis and Optimisation. Tech. Rep. 95.24, IFI, Univ. Zürich, 1995.Google Scholar
  10. [VF96a]
    W. W. Vasconcelos and N. E. Fuchs. An Opportunistic Approach for Logic Program Analysis and Optimisation using Enhanced Schema-Based Transformations. In Proc. 5th Int'l Workshop on Logic Program Synthesis and Transformation (LoPSTr'95), The Netherlands, 1996. Springer-Verlag.Google Scholar
  11. [VF96b]
    W. W. Vasconcelos and N. E. Fuchs. Prolog Program Development via Enhanced Schema-Based Transformations. Technical report, Department of Artificial Intelligence, University of Edinburgh, 1996.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1996

Authors and Affiliations

  • Wamberto W. Vasconcelos
    • 1
  • Marcelo A. T. Aragão
    • 2
  • Norbert E. Fuchs
    • 3
  1. 1.Statistics & Computing Dept.State Univ. of CearáFortaleza, Ce.Brazil
  2. 2.A. I. LabFederal Univ. of CearáFortaleza, Ce.Brazil
  3. 3.Institut für InformatikUniversität ZürichZürichSwitzerland

Personalised recommendations