Efficient Negation Using Abstract Interpretation

Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 2250)


While negation has been a very active area of research in logic programming, comparatively few papers have been devoted to implementation issues. Furthermore, the negation-related capabilities of current Prolog systems are limited. We recently presented a novel method for incorporating negation in a Prolog compiler which takes a number of existing methods (some modified and improved by us) and uses them in a combined fashion. The method makes use of information provided by a global analysis of the source code. Our previous work focused on the systematic description of the techniques and the reasoning about correctness and completeness of the method, but provided no experimental evidence to evaluate the proposal. In this paper, we provide experimental data which indicates that the method is not only feasible but also quite promising from the efficiency point of view. In addition, the tests have provided new insight as to how to improve the proposal further. Abstract interpretation techniques (in particular those included in the Ciao Prolog system preprocessor) are important for the strategy to success.


Negation in Logic Programming Constraint Logic Programming Program Analysis Implementations of Logic Programming Abstract Interpretation 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    R. Barbuti, D. Mancarella, D. Pedreschi, and F. Turini. Intensional negation of logic programs. Lecture notes on Computer Science, 250:96–110, 1987.Google Scholar
  2. 2.
    R. Barbuti, D. Mancarella, D. Pedreschi, and F. Turini. A transformational approach to negation in logic programming. JLP, 8(3):201–228, 1990.CrossRefMathSciNetzbMATHGoogle Scholar
  3. 3.
    C. Braem, B. Le Charlier, S. Modart, and P. Van Hentenryck. Cardinality analysis of Prolog. In ILPS, pages 457–471. The MIT Press, 1994.Google Scholar
  4. 4.
    F. Bueno. The CIAO Multiparadigm Compiler: A User’s Manual, 1995.Google Scholar
  5. 5.
    D. Chan. Constructive negation based on the complete database. In Proc. Int. Conference on LP’88, pages 111–125. The MIT Press, 1988.Google Scholar
  6. 6.
    D. Chan. An extension of constructive negation and its application in coroutining. In Proc. NACLP’89, pages 477–493. The MIT Press, 1989.Google Scholar
  7. 7.
    K. L. Clark. Negation as failure. In J. Minker H. Gallaire, editor, Logic and Data Bases, pages 293–322, New York, NY, 1978.Google Scholar
  8. 8.
    M. García, K. Marriott, and P. Stuckey. Efficient analysis of constraint logic programs with dynamic scheduling. In ILPS, pages 417–431. MIT Press, 1995.Google Scholar
  9. 9.
    M. Hermenegildo, F. Bueno, G. Puebla, and P. López-García. Program Analysis, Debugging and Optimization Using the Ciao System Preprocessor. In 1999 ICLP, pages 52–66, Cambridge, MA, November 1999. MIT Press.Google Scholar
  10. 10.
    K. Kunen. Negation in logic programming. JLP, 4:289–308, 1987.CrossRefMathSciNetzbMATHGoogle Scholar
  11. 11.
    E. Shapiro L. Sterling. The Art of Prolog. The MIT Press, 1987.Google Scholar
  12. 13.
    K. Muthukumar and M. Hermenegildo. Compile-time derivation of variable dependency using abstract interpretation. JLP, 13(2/3):315–347, July 1992.zbMATHCrossRefGoogle Scholar
  13. 14.
    L. Naish. Negation and Control in Prolog. In LNCS, number 238. Springe, 1985.Google Scholar
  14. 15.
    R. A. O’Keefe. The Craft of Prolog. The MIT Press, 1990.Google Scholar
  15. 16.
    G. Puebla, M. García, K. Marriott, and P. Stuckey. Optimization of Logic Programs with Dynamic Scheduling. In 1997 International Conference on LP, pages 93–107, Cambridge, MA, June 1997. MMIT Press.Google Scholar
  16. 17.
    J.J. Moreno S. Muñoz. How to incorporate negation in a prolog compiler. In V. Santos Costa E. Pontelli, editor, 2nd International Workshop PADL’2000, volume 1753 of LNCS, pages 124–140, Boston, MA (USA), 2000. Springer.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2001

Authors and Affiliations

  1. 1.Universidad Politécnica de Madrid Dpto.LSIIS - Facultad de InformáticaMadridSpain

Personalised recommendations