skip to main content
research-article

Lolliproc: to concurrency from classical linear logic via curry-howard and control

Published:27 September 2010Publication History
Skip Abstract Section

Abstract

While many type systems based on the intuitionistic fragment of linear logic have been proposed, applications in programming languages of the full power of linear logic - including double-negation elimination - have remained elusive. Meanwhile, linearity has been used in many type systems for concurrent programs - e.g., session types - which suggests applicability to the problems of concurrent programming, but the ways in which linearity has interacted with concurrency primitives in lambda calculi have remained somewhat ad-hoc. In this paper we connect classical linear logic and concurrent functional programming in the language Lolliproc, which provides simple primitives for concurrency that have a direct logical interpretation and that combine to provide the functionality of session types. Lolliproc features a simple process calculus "under the hood" but hides the machinery of processes from programmers. We illustrate Lolliproc by example and prove soundness, strong normalization, and confluence results, which, among other things, guarantees freedom from deadlocks and race conditions.

Skip Supplemental Material Section

Supplemental Material

icfp-mon-1240-mazurak.mov

References

  1. }}Samson Abramsky. Computational interpretations of linear logic. Theoretical Computer Science, 111:3--57, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. }}Amal Ahmed, Matthew Fluet, and Greg Morrisett. L3: A linear language with locations. Fundam. Inf., 77(4):397--449, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. }}Joe Armstrong, Robert Virding, Claes Wikström, and Mike Williams. Concurrent Programming in Erlang. Prentice-Hall, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. }}Emmanuel Beffara. A concurrent model for linear logic. Electronic Notes in Theoretical Computer Science, 155:147--168, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. }}G. Bellin and P. J. Scott. On the π-calculus and linear logic. Theoretical Computer Science, 135(1):11--65, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. }}Nick Benton, G. M. Bierman, J. Martin E. Hyland, and Valeria de Paiva. A term calculus for intuitionistic linear logic. In Proceedings of the International Conference on Typed Lambda Calculi and Applications, pages 75--90. Springer-Verlag LNCS 664, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. }}Josh Berdine. Linear and Affine Typing of Continuation-Passing Style. PhD thesis, Queen Mary, University of London, 2004.Google ScholarGoogle Scholar
  8. }}Josh Berdine, Peter W. O'Hearn, Uday S. Reddy, and Hayo Thielecke. Linearly used continuations. In Proceedings of the Continuations Workshop, 2001.Google ScholarGoogle Scholar
  9. }}G. M. Bierman, A. M. Pitts, and C. V. Russo. Operational properties of Lily, a polymorphic linear lambda calculus with recursion. In Fourth International Workshop on Higher Order Operational Techniques in Semantics, Montral, volume 41 of Electronic Notes in Theoretical Computer Science. Elsevier, 2000.Google ScholarGoogle Scholar
  10. }}Gavin Bierman. A classical linear lambda calculus. Theoretical Computer Science, 227(1-2):43--78, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. }}Gavin M. Bierman. Program equivalence in a linear functional language. Journal of Functional Programming, 10(2), 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. }}Luís Caires and Frank Pfenning. Session types as intuitionistic linear propositions. In Proceedings of the 21st International Conference on Concurrency Theory (CONCUR 2010), Paris, France, August 2010. Springer LNCS. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. }}Arthur Charguéraud and François Pottier. Functional translation of a calculus of capabilities. In ICFP '08: Proceeding of the 13th ACM SIGPLAN international conference on Functional programming, pages 213--224, New York, NY, USA, 2008. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. }}Valeria de Paiva and Eike Ritter. A parigot-style linear lambda-calculus for full intuitionistic linear logic. Theory and Applications of Categories, 17(3), 2006.Google ScholarGoogle Scholar
  15. }}Manuel Fähndrich, Mark Aiken, Chris Hawblitzel, Orion Hodson, Galen Hunt, James R. Larus, and Steven Levi. Language support for fast and reliable message-based communication in singularity os. SIGOPS Oper. Syst. Rev., 40(4):177--190, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. }}Manuel Fähndrich and Robert DeLine. Adoption and focus: Practical linear types for imperative programming. In Proc. of the SIGPLAN Conference on Programming Language Design, pages 13--24, Berlin, Germany, June 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. }}M. Felleisen and R. Hieb. A revised report on the syntactic theories of sequential control and state. Theoretical Computer Science, 103(2):235--271, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. }}Andrzej Filinski. Declarative continuations and categorical duality. Master's thesis, University of Copenhagen, August 1989.Google ScholarGoogle Scholar
  19. }}Andrzej Filinski. Linear continuations. In Proc. 19th ACM Symp. on Principles of Programming Languages (POPL), pages 27--38, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. }}C. Fournet and G. Gonthier. The Reflexive CHAM and the Join-Calculus. In Proc. ACM Symp. on Principles of Programming Languages (POPL), pages 372--385, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. }}Cédric Fournet. The Join-Calculus: a Calculus for Distributed Mobile Programming. PhD thesis, École Polytechnique, nov 1998.Google ScholarGoogle Scholar
  22. }}Jean-Yves Girard. Linear logic. Theoretical Computer Science, 50:1--102, 1987. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. }}Timothy G. Griffin. A formulae-as-types notion of control. In Conference Record of the Seventeenth Annual ACM Symposium on Principles of Programming Languages, pages 47--58. ACM Press, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. }}Michael Hicks, Greg Morrisett, Dan Grossman, and Trevor Jim. Experience with safe manual memory-management in Cyclone. In ISMM '04: Proceedings of the 4th international symposium on Memory management, pages 73--84, New York, NY, USA, 2004. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. }}Kohei Honda, Vasco T. Vasconcelos, and Makoto Kubo. Language primitives and type discipline for structured communication-based programming. In ESOP98, volume 1381 of LNCS, pages 122--138. Springer-Verlag, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. }}W. A. Howard. The formulae-as-types notion of contstruction. In To H. B. Curry: Essays on Combinatory Logic, Lambda Calculus, and Formalism. Academic Press, 1980.Google ScholarGoogle Scholar
  27. }}Naoki Kobayashi. Type systems for concurrent programs. In Proceedings of UNU/IIST 10th Anniversary Cooloquium, March 2002.Google ScholarGoogle Scholar
  28. }}Naoki Kobayashi, Benjamin C. Pierce, and David N. Turner. Linearity and the Pi-Calculus. Transactions on Programming Languages and Systems, 21(5):914--947, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. }}Yves Lafont. The linear abstract machine. Theoretical Computer Science, 59:157--180, 1988. Corrections in vol. 62, pp. 327--328. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. }}John Maraist, Martin Odersky, David N. Turner, and Philip Wadler. Call-by-name, call-by-value, call-by-need, and the linear lambda calculus. In 11'th International Conference on the Mathematical Foundations of Programming Semantics, New Orleans, Lousiana, - 1995.Google ScholarGoogle Scholar
  31. }}Karl Mazurak, Jianzhou Zhao, and Steve Zdancewic. Lightweight linear types in System F0. In TLDI '10: Proceedings of the 5th ACM SIGPLAN workshop on Types in language design and implementation, pages 77--88, New York, NY, USA, 2010. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. }}R. Milner, J. Parrow, and D. Walker. A calculus of mobile processes. Information and Computation, 100(1):1--77, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. }}J. Niehren, J. Schwinghammer, and G. Smolka. A concurrent lambda calculus with futures. Theor. Comput. Sci., 364(3):338--356, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. }}C.-H. L. Ong and C. A. Stewart. A curry-howard foundation for functional computation with control. In Proc. 24th ACM Symp. on Principles of Programming Languages (POPL), pages 215--227, Paris, France, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. }}Michel Parigot. λµ-calculus: An algorithmic interpretation of classical natural deduction. In Proceedings of the International Conference on Logic Programming and Automated Reasoning, volume 624 of Lecture Notes in Computer Science, pages 190--201. Springer, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. }}Michel Parigot. Classical proofs as programs. In Proceedings of the 3rd Kurt Gödel Colloquium, volume 713 of Lecture Notes in Computer Science, pages 263--276. Springer-Verlag, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. }}Eike Ritter, David J. Pym, and Lincoln A. Wallen. Proof-terms for classical and intuitionistic resolution. Journal of Logic and Computation, 10(2):173--207, 2000.Google ScholarGoogle ScholarCross RefCross Ref
  38. }}Kaku Takeuchi, Kohei Honda, and Makoto Kubo. An interaction-based language and its typing system. In Proceedings of PARLE'94, pages 398--413. Springer-Verlag, 1994. Lecture Notes in Computer Science number 817. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. }}David N. Turner and Philip Wadler. Operational interpretations of linear logic. Theoretical Computer Science, 227(1--2):231--248, September 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. }}Vasco T. Vasconcelos, Simon J. Gay, and António Ravara. Type checking a multithreaded functional language with session types. Theoretical Computer Science, 368(1-2):64--87, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. }}Edsko Vries, Rinus Plasmeijer, and David M. Abrahamson. Uniqueness typing simplified. In Implementation and Application of Functional Languages: 19th International Workshop, IFL 2007, Freiburg, Germany, September 27-29, 2007. Revised Selected Papers, pages 201--218, Berlin, Heidelberg, 2008. Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  42. }}Philip Wadler. Linear types can change the world! In M. Broy and C. Jones, editors, Progarmming Concepts and Methods, Sea of Galilee, Israel, April 1990. North Holland. IFIP TC 2 Working Conference.Google ScholarGoogle Scholar
  43. }}Philip Wadler. Call-by-value is dual to call-by-name. In ICFP '03: Proceedings of the eighth ACM SIGPLAN international conference on Functional programming, pages 189--201, New York, NY, USA, 2003. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  44. }}Philip Wadler. Down with the bureaucracy of syntax! Pattern matching for classical linear logic. unpublished manuscript, 2004.Google ScholarGoogle Scholar
  45. }}Nobuko Yoshida, Kohei Honda, and Martin Berger. Linearity and bisimulation. J. Log. Algebr. Program., 72(2):207--238, 2007.Google ScholarGoogle ScholarCross RefCross Ref
  46. }}Noam Zeilberger. On the unity of duality. Annals of Pure and Applied Logic, 153(1-3):66--96, 2006.Google ScholarGoogle ScholarCross RefCross Ref
  47. }}Dengping Zhu and Hongwei Xi. Safe Programming with Pointers through Stateful Views. In Proceedings of the 7th International Symposium on Practical Aspects of Declarative Languages, pages 83--97, Long Beach, CA, January 2005. Springer-Verlag LNCS vol. 3350. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Lolliproc: to concurrency from classical linear logic via curry-howard and control

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      • Published in

        cover image ACM SIGPLAN Notices
        ACM SIGPLAN Notices  Volume 45, Issue 9
        ICFP '10
        September 2010
        382 pages
        ISSN:0362-1340
        EISSN:1558-1160
        DOI:10.1145/1932681
        Issue’s Table of Contents
        • cover image ACM Conferences
          ICFP '10: Proceedings of the 15th ACM SIGPLAN international conference on Functional programming
          September 2010
          398 pages
          ISBN:9781605587943
          DOI:10.1145/1863543

        Copyright © 2010 ACM

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 27 September 2010

        Check for updates

        Qualifiers

        • research-article

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader

      ePub

      View this article in ePub.

      View ePub
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!