Skip to main content

Optimising Bytecode Emulation for Prolog

  • Conference paper
Principles and Practice of Declarative Programming (PPDP 1999)

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

Abstract

Byte-code representation has been used to implement several programming languages such as Lisp, ML, Prolog, or Java. In this work, we discuss the impact of several emulator optimisations for the Prolog system YAP. YAP obtains performance comparable or exceeding well-known Prolog systems by applying several different styles of optimisations, such as improving the emulation mechanism, exploiting the characteristics of the underlying hardware, and improving the abstract machine itself. We give throughout a detailed performance analysis, demonstrating that low-level optimisations can have a very significant impact on the whole system and across a range of architectures.

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. Andersson, J., Andersson, S., Boortz, K., Carlsson, M., Nilsson, H., Sjoland, T., Widén, J.: SICStus Prolog User’s Manual. Technical report, Swedish Institute of Computer Science, SICS Technical Report T93-01 (November 1997)

    Google Scholar 

  2. Arnold, K., Gosling, J.: The Java Programming Language. Addison Wesley, Reading (1996)

    MATH  Google Scholar 

  3. Bell, J.R.: Threaded code. Communications of the ACM 16(6), 370–372 (1973)

    Article  Google Scholar 

  4. Bueno, F.,, M.G.: Effectiveness of Abstract Interpretation in Automatic Parallelization: A Case Study in Logic Programming. ACM TOPLAS (1998)

    Google Scholar 

  5. Carlsson, M.: On the efficiency of optimised shallow backtracking in Compiled Prolog. In: Proceedings of the Sixth International Conference on Logic Programming, pp. 3–15. MIT Press, Cambridge (1989)

    Google Scholar 

  6. Carlsson, M.: Design and Implementation of an OR-Parallel Prolog Engine. SICS Dissertation Series 02, The Royal Institute of Technology (1990)

    Google Scholar 

  7. Codognet, P., Diaz, D.: wamcc: Compiling Prolog to C. In: 12th International Conference on Logic Programming. The MIT Press, Cambridge (1995)

    Google Scholar 

  8. Damas, L., Santos Costa, V., Reis, R., Azevedo, R.: YAP User’s Guide and Reference Manual (1998), http://www.ncc.up.pt/vsc/Yap

  9. Debaere, E.H., Van Campenhout, J.M.: Interpretation and Instruction Path Coprocessing. The MIT Press, Cambridge (1990)

    Google Scholar 

  10. Ertl, M.A.: Stack caching for interpreters. In: SIGPLAN 1995 Conference on Programming Language Design and Implementation, pp. 315–327 (1995)

    Google Scholar 

  11. Gabriel, R.P.: Performance and evaluation of Lisp systems. MIT Press, Cambridge (1985)

    Google Scholar 

  12. Haygood, R.C.: Native code compilation in SICStus Prolog. In: Hentenryck, P.V. (ed.) Proceedings of the Eleventh International Conference on Logic Programming, MIT Press, Cambridge (1994)

    Google Scholar 

  13. Hermenegildo, M., Puebla, G., Marriott, K., Stuckey, P.: Incremental Analysis of Logic Programs. In: International Conference on Logic Programming, pp. 797–811. MIT Press, Cambridge (1995)

    Google Scholar 

  14. Klint, P.: Interpretation techniques. Software Practice and Experience 11, 963–973 (1981)

    Article  Google Scholar 

  15. Le Charlier, B., Van Hentenryck, P.: Experimental evaluation of a generic abstract interpretation algorithm for PROLOG. ACM TOPLAS 16(1), 35–101 (1994)

    Article  Google Scholar 

  16. Magnusson, P.S., Larsson, F., Moestedt, A., Werner, B., Dahlgren, F., Karlsson, M., Lundholm, F., Nilsson, J., Stenström, P., Grahn, H.: SimICS/sun4m: A virtual workstation. In: Proceedings of the USENIX 1998 Annual Technical Conference, Berkeley, USA, June 15-19, pp. 119–130 USENIX Association (1998)

    Google Scholar 

  17. Milner, R., Tofte, M., Harper, R.: The Definition of Standard ML. MIT Press, Cambridge (1990)

    Google Scholar 

  18. Jones, S.L.P., Nordin, T., Oliva, D.: C–: A Portable Assembly Language. In: Clack, C., Hammond, K., Davie, T. (eds.) IFL 1997. LNCS, vol. 1467, p. 1. Springer, Heidelberg (1998)

    Chapter  Google Scholar 

  19. Proebsting, T.A.: Optimizing an ANSI C interpreter with superoperators. In: Principles of Programming Languages (POPL 1995), pp. 322–332 (1995)

    Google Scholar 

  20. Romer, T.H., Lee, D., Voelker, G.M., Wolman, A., Wong, W.A., Baer, J.-L., Bershad, B.N., Levy, H.M.: The structure and performance of interpreters. In: Architectural Support for Programming Languages and Operating Systems (ASPLOS-VII), pp.150–159 (1996)

    Google Scholar 

  21. Rosenblum, M., Herrod, S.A., Witchel, E., Gupta, A.: Complete computer system simulation: The SimOS approach. IEEE parallel and distributed technology: systems and applications 3(4), 34–43 (Winter 1995)

    Google Scholar 

  22. Santos Costa, V.: ImplementaĂ§Ă£o de Prolog. In: Provas de aptidĂ£o pedagĂ³gica e capacidade cientĂ­fica. Universidade do Porto, Dezembro (1988)

    Google Scholar 

  23. Stallman, R.M.: Using and porting gcc. Technical report, The Free Software Foundation (1993)

    Google Scholar 

  24. Sterling, L., Shapiro, E.: The Art of Prolog. MIT Press, Cambridge (1994)

    MATH  Google Scholar 

  25. Sussman, G.J., Steele Jr., G.L., Gabriel, R.P.: A brief introduction to Lisp. ACM SIGPLAN Notices 28(3), 361–362 (1993)

    Article  Google Scholar 

  26. Tarau, P., De Bosschere, K., Demoen, B.: Partial Translation: Towards a Portable and Efficient Prolog Implementation Technology. Journal of Logic Programming 29(1–3), 65–83 (1996)

    Article  MATH  Google Scholar 

  27. Taylor, A.: Parma–bridging the performance gap between imperative and logic programming. The Journal of Logic Programming, 1–3 (October 1996)

    Google Scholar 

  28. Van Roy, P.: Can Logic Programming Execute as Fast as Imperative Programming? PhD thesis, University of California at Berkeley (November 1990)

    Google Scholar 

  29. Van Roy, P.: 1983-1993: The Wonder Years of Sequential Prolog Implementation. The Journal of Logic Programming, 19–20 (May/July 1994)

    Google Scholar 

  30. Warren, D.H.D.: An Abstract Prolog Instruction Set. Technical Note 309, SRI International (1983)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 1999 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Costa, V.S. (1999). Optimising Bytecode Emulation for Prolog. In: Nadathur, G. (eds) Principles and Practice of Declarative Programming. PPDP 1999. Lecture Notes in Computer Science, vol 1702. Springer, Berlin, Heidelberg. https://doi.org/10.1007/10704567_16

Download citation

  • DOI: https://doi.org/10.1007/10704567_16

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-66540-3

  • Online ISBN: 978-3-540-48164-5

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics