skip to main content
article
Free Access

Efficient execution of programs with static semantics

Authors Info & Claims
Published:01 April 1995Publication History
Skip Abstract Section

Abstract

An extension to single-threading (using each value exactly once) is presented that allows efficient execution of functional programs while maintaining their static semantics. This extension preserves the idea of only one, possibly modifying, use of a data item, and also allows any number of read-only uses. The inefficiency problem is overcome by imposing a restriction on function composition. The proposed method is based upon a static analysis of function definitions and calls. This analysis is linear in the size of function definitions, and additive between functions. Unlike approaches utilized in optimizing compilers, the proposed method can be applied even to large programs, and it guarantees the asymptotic complexity of corresponding imperative programs while obviating the need for garbage collection. An experimental functional programming language based on these ideas has been designed and implemented.

References

  1. [Bac78] John Backus: "Can Programming Be Liberated from the von Neumann Style? A Functional Style and Its Algebra of Programs", Communications of ACM, August 1978. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. [Bac81a] John Backus: "Is Computer Science Based on the Wrong Fundamental Concept of 'Program'? An extended Concept", Algorithmic Languages, de Bakker/van Vliet(eds.), IFIP, North-Holland Publishing Company, 1981.Google ScholarGoogle Scholar
  3. [Bac81b] John Backus: "Function, Level Programs as Mathematical Objects", Proc. of the 1981 Conference on Functional Programming Languages and Computer Architecture, ACM 1981. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. [Bau76] F. L. Bauer: "A Philosophy of Programming. Appendix: Variables considered harmful", Language Hierarchies and Interfaces, LNCS 46, Springer-Verlag, 1976.Google ScholarGoogle Scholar
  5. [BF88] Eike Best, César Fernández C.: Nonsequential Processes. A Petri Net View, Springer-Verlag, 1988.Google ScholarGoogle Scholar
  6. [BJM91] J. -P. Banâtre, S. B. Jones, D. Le Métayer: Prospects for Functional Programming in Software Engineering, ESPRIT Research Report, Springer-Verlag, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. [Blo89] Adrienne Bloss: "Update Analysis and the Efficient Implementation of Functional Aggregates", Proceedings of the 1989 Conference on Functional Programming Languages and Computer Architecture, ACM 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. [BM93] George Becker, Neil V. Murray: A Structured Approach to Referentially Transparent Programming, TR 93-11, Dept. of Computer Science, SUNY Albany, 1993.Google ScholarGoogle Scholar
  9. [BM94] George Becker, Neil V. Murray: "Graph Models for Structured Functional Programming," Proc. of the 2-nd Massey Functional Programming Workshop, January 1994, New Zealand.Google ScholarGoogle Scholar
  10. [BRR89] J. W. de Bakker, W. -P. de Roever, G. Rozenberg: Linear Time, Branching Time and Partial Order in Logics and Models of Concurrency, LNCS 354, Springer-Verlag, 1989.Google ScholarGoogle Scholar
  11. [BS93] Erik Barendsen, Sjaak Smetsers: "Conventional and Uniqueness Typing in Graph Rewrite Systems", Proceedings of the 13-th Conference on Foundations of Software Technology and Theoretic Computer Science, LNCS 761, Springer-Verlag, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. [Dar93] J. Darlington et al.: "Parallel Programming Using Skeleton Functions", Parallel Architectures and Languages Europe, LNCS 694, Springer-Verlag 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. [GH90] Juan C. Guzmán, Paul Hudak: "Single-threaded polymorphic lambda calculus", Proceedings of the 5th Annual Symposium on Logic in Computer Science, IEEE, June 1990.Google ScholarGoogle ScholarCross RefCross Ref
  14. [Gir87] Jean-Yves Girard: "Linear logic", Theoretical Computer Science, 50:1-102, 1987. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. [Gun93] J. Gunawardena: "A Generalized Event Structure for the Muller Unfolding of a Safe Net", 4th International Conference on Concurrency Theory, LNCS 715, Springer-Verlag 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. [Jen92] Kurt Jensen: Coloured Petri Nets, Springer-Verlag, 1992.Google ScholarGoogle ScholarCross RefCross Ref
  17. [JR91] K. Jensen, G. Rozenberg: High-level Petri nets. Theory and applic., Springer-Verlag, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. [Kel89] Paul Kelly: Functional Programming for Loosely-coupled Multiprocessors, Pitman, 1989.Google ScholarGoogle Scholar
  19. [Laf88] Yves Lafont: "The linear abstract machine", Theoretical Computer Science, 59, 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. [Lan66] Peter Landin: "The Next 700 Programming Languages", Comm. ACM, March 1966. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. [Mull59] D. E. Muller, W. S. Bartky: "A theory of asynchronous circuits." In Proceedings of an International Symposium on the Theory of Switching. Harvard University Press, 1959.Google ScholarGoogle Scholar
  22. [Nag79] Manfred Nagl: Graph-Grammatiken: Theorie, Implementierung, Anwendungen, Vieweg, Braunschweig, 1979.Google ScholarGoogle Scholar
  23. [NPW81] Mogens Nielsen, Gordon Plotkin and Glynn Winskel: "Petri nets, event structures and domains, part I', Theoretical Computer Science, 13, 1981.Google ScholarGoogle Scholar
  24. [Ode91] Martin Odersky: "How to Make Destructive Updates Less Destructive", Symposium on Principles of Programming Languages, ACM 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. [Ode92] Martin Odersky: "Observers for Linear Types", Proceedings of the fourth European Symposium on Programming, LNCS 582, Springer-Verlag 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. [PE93] Rinus Plasmeijer, Marko van Eekelen: Functional Programming and Parallel Graph Rewriting, Addison-Wesley, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. [Pet62] Carl A. Petri: Kommunication mit Automaten, PhD thesis, Univ. Bonn, 1962.Google ScholarGoogle Scholar
  28. [Pet77] Carl A. Patri: Non-sequential processes, Technical Report GMD-ISF-77-5, Gessellschaft Math. Dataverarb., St. Augustin, 1977.Google ScholarGoogle Scholar
  29. [Pra86] Vaugham Pratt: "Modeling Concurrency with Partial Orders", International Journal of Parallel Programming, Vol. 15, No. 1, 1986 Plenum Publishing Corporation, 1986. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. [Qui60] Willard Van Orman Quine: Word and Object, MIT Press, 1960.Google ScholarGoogle Scholar
  31. [Rei85] Wolfgang Reisig: Petri Nets. An Introduction, Springer-Verlag, 1985. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. [Sch85] David A. Schmidt: "Detecting global variables in denotational specifications", ACM Transactions on Programming Languages and Systems, 7(2), April 1985. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. [Wad91] Philip Wadler: "Is there a use for linear logic?", Proceedings of the ACM Symposium on Partial Evaluation and Semantics-Based Program Manipulation, ACM, June. 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. [Wad90] Philip Wadler: "Linear types can change the world!", Proceedings of the IFIP TC2 Working Conference on Programming Concepts and Methods, Elsevier Science Publishers B.V.(North-Holland), April 1990.Google ScholarGoogle Scholar

Index Terms

  1. Efficient execution of programs with static semantics

              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 30, Issue 4
                April 1995
                74 pages
                ISSN:0362-1340
                EISSN:1558-1160
                DOI:10.1145/202176
                Issue’s Table of Contents

                Copyright © 1995 Authors

                Publisher

                Association for Computing Machinery

                New York, NY, United States

                Publication History

                • Published: 1 April 1995

                Check for updates

                Qualifiers

                • article

              PDF Format

              View or Download as a PDF file.

              PDF

              eReader

              View online with eReader.

              eReader