Advertisement

An Efficient Abstract Machine for Curry

  • Wolfgang Lux
  • Herbert Kuchen
Part of the Informatik aktuell book series (INFORMAT)

Abstract

The functional logic programming language Curry integrates features from functional, logic, and concurrent programming. It combines lazy evaluation, higher-order functions, logic variables, partial data structures, built-in search and the concurrent evaluation of (equational) constraints. Curry amalgamates the most important operational principles developed in the area of integrated functional logic languages: residuation and narrowing. The effects of non-determinism stemming from the narrowing semantics can be encapsulated using the primitive try operator. This is necessary to implement declarative I/O in the presence of non-deterministic computations and allows to implement different search strategies.

In the present paper we develop an abstract machine for the implementation of Curry. The focus in this paper will be on the efficient implementation of encapsulated search in a lazy functional logic language.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. [ALN87]
    H. Alt-Kaci, P. Lincoln, and R. Nasr. Le Fun: Logic, equations, and functions. In Proc. 4th ILPS, pages 17–23, 1987.Google Scholar
  2. [Gup94]
    G. Gupta. Multiprocessor Execution of Logic Programs. Kluwer, 1994.Google Scholar
  3. [Han94]
    M. Hanus. The integration of functions into logic programming: From theory to practice. Journal of Logic Programming, 19 and 20: 583–628, 1994.MathSciNetCrossRefGoogle Scholar
  4. [Han99]
    M. Hanus. Curry: An integrated functional logic language, (version 0.5). http://www-i2.informatik.rwth-aachen.de/`hanus/curry, 1999.Google Scholar
  5. [HCS95]
    F. Henderson, Th. Conway, and Z. Somogyi. Compiling logic programs to C using GNU C as a portable assembler. In Proc. of the ILPS ‘85 Postconference Workshop on Sequential Implementation Technologies for Logic Programming Languages, pages 1–15, 1995.Google Scholar
  6. [HKM95]
    M. Hanus, H. Kuchen, and J. Moreno-Navarro. Curry: A truly functional logic language. In Proc. ILPS’95 Workshop on Visions for the Future of Logic Programming, pages 95–107, 1995.Google Scholar
  7. [HPW92]
    P. Hudak, S. Peyton Jones, and P. Wadler. Report on the programming language Haskell (version 1.2). SIGPLAN Notices, 27 (5), 1992.Google Scholar
  8. [HS97]
    M. Hanus and R. Sadre. A concurrent implementation of Curry in Java. In Proc. ILPS’97 Workshop on Parallelism and Implementation Technology for (Constraint) Logic Programming Languages, 1997.Google Scholar
  9. [HS98]
    M. Hanus and F. Steiner. Controlling search in functional logic programs. In Proc. PLILP’98, 1998.Google Scholar
  10. [Joh87]
    T. Johnsson. Compiling lazy functional languages. PhD thesis, Chalmers Univ. of Technology, 1987.Google Scholar
  11. [KLMR96]
    H. Kuchen, R. Loogen, J. Moreno-Navarro, and M. Rodriguez-Artalejo. The functional logic language Babel and its implementation on a graph machine. New Generation Computing, 14: 391–427, 1996.CrossRefGoogle Scholar
  12. [Loo93]
    R. Loogen. Relating the implementation techniques of functional and functional logic languages. New Generation Computing, 11: 179–215, 1993.zbMATHCrossRefGoogle Scholar
  13. [Mi178]
    R. Milner. A theory of type polymorphism in programming. Journal of Computer System Science, 17 (3), 1978.Google Scholar
  14. [MSS95]
    M. Mehl, R. Scheidhauer, and Ch. Schulte. An abstract machine for Oz. In Proc. PLILP’95,pages 151–168. Springer, LNCS 982, 1995..Google Scholar
  15. [Pey92]
    S. Peyton Jones. Implementing lazy functional languages on stock hardware: The spineless tagless G-machine. Journal of Functional Programming, 2 (1): 73–80, Jan 1992.CrossRefGoogle Scholar
  16. [PW93]
    S. Peyton Jones and P. Wadler. Imperative functional programming. In Proc. 20th POPL’93, pages 123–137, 1993.Google Scholar
  17. [Red85]
    U. Reddy. Narrowing as the operational semantics of functional languages. In Proc. ILPS’85, pages 138–151, 1985.Google Scholar
  18. [Smo95]
    G. Smolka. The Oz programming model. In J. van Leeuwen, editor, Current Trends in Computer Science. Springer LNCS 1000, 1995.Google Scholar
  19. [SS86]
    L. Sterling and E. Shapiro. The Art of Prolog. MIT Press, 1986.Google Scholar
  20. [War83]
    D. Warren. An abstract Prolog instruction set. TR 309, SRI, 1983.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1999

Authors and Affiliations

  • Wolfgang Lux
    • 1
  • Herbert Kuchen
    • 1
  1. 1.Universität MünsterGermany

Personalised recommendations