Skip to main content

A Simple Scheme for Implementing Tabled Logic Programming Systems Based on Dynamic Reordering of Alternatives

  • Conference paper
  • First Online:
Logic Programming (ICLP 2001)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2237))

Included in the following conference series:

Abstract

Tabled logic programming (LP) systems have been applied to elegantly and quickly solving very complex problems (e.g., model checking). However, techniquescurren tly employed for incorporating tabling in an existing LP system are quite complex and require considerable change to the LP system. We present a simple technique for incorporating tabling in existing LP systems based on dynamically reordering clauses containing variant callsat run-time. Our simple technique allows tabled evaluation to be performed with a single SLD tree and without the use of complex operations such as freezing of stacks and heap. It can be incorporated in an existing logic programming system with a small amount of effort. Our scheme also facilitates exploitation of parallelism from tabled LP systems. Results of incorporating our scheme in the commercial ALS Prolog system are reported.

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

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. K. Bowen, C. Houpt, et al. ALS Prolog System. http://www.als.com.

  2. W. Chen and D. S. Warren. Tabled Evaluation with Delaying for General Logic Programs. JACM, 43(1):20–74, January 1996.

    Article  MATH  MathSciNet  Google Scholar 

  3. W. Chen, T. Swift, and D. Warren. Efficient top-down computation of queries under the well-founded semantics. J. Logic Programming, 24(3):161–199.

    Google Scholar 

  4. S. Das. Deductive Databases and Logic Programming. Addison Wesley. 1992.

    Google Scholar 

  5. B. Demoen and K. Sagonas. CHAT: the Copy-Hybrid Approach to Tabling. PADL’ 99, Springer Verlag LNCS 1551, pages106–121.

    Google Scholar 

  6. J. Freire, R. Hu, T. Swift, D. Warren. Exploiting Parallelism in Tabled Evaluations. PLILP 1995: 115–132. LNCS 982.

    Google Scholar 

  7. J. Freire, T. Swift, D. S. Warren. Beyond Depth-First Strategies: Improving Tabled Logic Programs through Alternative Scheduling. JFLP 1998(3). MIT Press.

    Google Scholar 

  8. G. Gupta, E. Pontelli. Stack-splitting: A Simple Technique for Implementing Orparallelism in Logic Programming Systems. In Proc.ICLP, 1999. pp. 290–305.

    Google Scholar 

  9. Hai-Feng Guo. High Performance Logic Programming. New Mexico State University. Ph.D. thesis. Oct. 2000.

    Google Scholar 

  10. H-F Guo, G. Gupta. A Simple Scheme for Implementing Tabled LP Systems. UT Dallas Tech. Rep 02-01. 2001.

    Google Scholar 

  11. J.W. Lloyd. Foundations of Logic Programming. Springer-Verlag, 1987.

    Google Scholar 

  12. E. Pontelli, G. Gupta. On the Duality between Or-parallelism and And-parallelism. In EuroPar’ 95, Springer LNCS 966, pp. 43–54.

    Google Scholar 

  13. C. R. Ramakrishnan, S. Dawson, and D. Warren. Practical Program Analysis Using General Purpose Logic Programming Systems. In Proc.A CM PLDI. 1996.

    Google Scholar 

  14. P. Rao, I. V. Ramakrishnan, et al. Efficient table access mechanisms for logic programs. Journal of Logic Programming, 38(1):31–54, Jan. 1999.

    Article  MATH  Google Scholar 

  15. Ricardo Rocha, Fernando M. A. Silva, Vítor Santos Costa. Or-Parallelism within Tabling. PADL 1999: 137–151. Springer LNCS 1551.

    Google Scholar 

  16. K. Sagonasand T. Swift. An abstract machine for tabled execution of fixed-order stratified logic programs. ACM TOPLAS, 20(3):586–635, May 1998.

    Article  Google Scholar 

  17. Hisao Tamaki, T. Sato. OLD Resolution with Tabulation. In ICLP 1986. pp. 84–98.

    Google Scholar 

  18. T. Swift and David S. Warren. An Abstract Machine for SLG Resolution: Definite Programs. SLP 1994: 633–652.

    Google Scholar 

  19. K. Villaverde, H-F. Guo, E. Pontelli, G. Gupta. Incremental Stack Splitting and Scheduling in the Or-parallel PALS System. Int’l Conf. on Par. Proc. 2001.

    Google Scholar 

  20. Neng-Fa Zhou, et al. Implementation of a Linear Tabling Mechanism. PADL 2000: 109–123. Springer LNCS 1753.

    Google Scholar 

  21. V. Santos Costa et al. Andorra-I: A Parallel Prolog system that transparently exploitsb oth And-and Or-Parallelism. Proc.A CM PPoPP, Apr.’ 91, pp. 83–93.

    Google Scholar 

  22. D. S. Warren. The XWAM: A machine that integratesProlog and deductive database query evaluation. TR 89/25, SUNY at Stony Brook, 1989.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2001 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Guo, HF., Gupta, G. (2001). A Simple Scheme for Implementing Tabled Logic Programming Systems Based on Dynamic Reordering of Alternatives. In: Codognet, P. (eds) Logic Programming. ICLP 2001. Lecture Notes in Computer Science, vol 2237. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-45635-X_20

Download citation

  • DOI: https://doi.org/10.1007/3-540-45635-X_20

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-42935-7

  • Online ISBN: 978-3-540-45635-3

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics