A new array operation

  • Philip Wadler
Part of the Lecture Notes in Computer Science book series (LNCS, volume 279)


A new monolithic array operation has been proposed. The operation is similar to earlier proposals, except that it uses the fold operation to combine multiple values with the same index. The new operation conveniently handles certain important kinds of computation, such as histogram, and provides parallelism in a convenient way.

This method solves the important problem of calculating histograms in a fashion suitable for parallel computation. I-structures, devised by Arvind and his colleagues, sacrifice referential transparency in order to increase the opportunities for parallelism, but do not provide a good solution to the histogram problem. I am grateful to Arvind for pointing out this defect of I-structures, which in turn inspired this paper.

Although the method presented here is useful for an important class of problems, it is not the best solution for all problems involving arrays. Further experience is needed to assess its advantages and shortcomings.


Incremental Approach Functional Language Graph Reduction Monolithic Approach Array Operation 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. [ANP86]
    Arvind, R. S. Nikhil, and K. Pengali. Id Nouveau Manual. Computation Structures Group Memo 265, MIT, 1986.Google Scholar
  2. [Bir86]
    R. S. Bird. An introduction to the theory of lists. In Marktoberdorf Workshop on Logics of Programming, August 1986.Google Scholar
  3. [HB85]
    P. Hudak and A. Bloss. The aggregate update problem in functional programming systems. In 12th ACM Symposium on Principles of Programming Languages, pages 300–314, 1985.Google Scholar
  4. [Hol83]
    Sören Holmström. A simple and efficient way to handle large data structures in applicative languages. In Proceedings SERC/Chalmers Workshop on Declarative Programming, University College London, 1983.Google Scholar
  5. [Hol86]
    Sören Holmström. Types for unshared objects in functional programming. Chalmers University of Technology, Göteborg, Sweden, 1986. To appear.Google Scholar
  6. [Hud84]
    P. Hudak. ALFL Reference Manual and Programmer's Guide. Research Report YALEU/DCS/RR-322, Second Edition, Yale University, October 1984.Google Scholar
  7. [Hud86]
    P. Hudak. A semantic model of reference counting and its abstraction (detailed summary). In ACM Symposium on Lisp and Functional Programming, pages 351–363, August 1986.Google Scholar
  8. [Hug85]
    R. J. M. Hughes. An efficient implementation of purely functional arrays. Technical Report, Programming Methodology Group, Chalmers University of Technology, Göteborg, Sweden, 1985.Google Scholar
  9. [Kel80]
    R. Keller. Divide and CONCer. In ACM Symposium on Lisp, pages 196–202, Palo Alto, California, August 1980.Google Scholar
  10. [Kel82]
    R.M. Keller. FEL programmer's guide. Technical Report AMPS TR 7, University of Utah, March 1982.Google Scholar
  11. [Mee84]
    L. Meertens. Algorithmics: towards programming as a mathematical activity. In J. W. de Bakker, et. al., editor, Mathematics and Computer Science, North-Holland, 1984.Google Scholar
  12. [Sch85]
    D. A. Schmidt. Detecting global variables in denotational specifications. ACM Transactions on Programming Languages and Systems, 7:299–310, 1985.CrossRefGoogle Scholar
  13. [SH82]
    M. R. Sleep and S. Holmström. A short note concerning lazy reduction rules of append. Software Practice and Experience, 12(11):1082–4, November 1982.Google Scholar
  14. [SH86]
    G. L. Steele Jr. and W. D. Hillis. Connection Machine Lisp: fine-grained parallel symbolic processing. In ACM Symposium on Lisp and Functional Programming, pages 279–297, Cambridge, Massachusetts, August 1986.Google Scholar
  15. [Sto85]
    W. Stoye. The Implementation of Functional Languages using Custom Hardware. PhD thesis, Cambridge University, December 1985. Computer Laboratory Technical Report No. 81.Google Scholar
  16. [Tur81]
    D. A. Turner. Recursion equations as a programming language. In J. Darlington, P. Henderson, and D. Turner, editors, Functional Programming and Its Applications, Cambridge University Press, 1981.Google Scholar
  17. [Tur85]
    D. A. Turner. Miranda: A non-strict functional language with polymorphic types. In Proceedings of the Conference on Functional Programming Languages and Computer Architecture, Springer-Verlag, September 1985.Google Scholar
  18. [Tur86]
    D. A. Turner. Applicative arrays—an alternative proposal. Technical Memo, Burroughs Austin Research Center, April 1986.Google Scholar
  19. [Wis85]
    D. S. Wise. Representing matrices as quadtrees for parallel processors. Information Processing Letters, 20:195–199, May 1985.CrossRefGoogle Scholar
  20. [Wis86]
    D. S. Wise. Parallel decomposition of matrix inversion using quadtrees. In International Conference on Parallel Processing, pages 92–99, 1986. (IEEE Cat. No. 86CH2355-6).Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1987

Authors and Affiliations

  • Philip Wadler
    • 1
    • 2
  1. 1.Programming Research GroupOxford UniversityUK
  2. 2.Programming Methodology GroupChalmers UniversityGöteborgSweden

Personalised recommendations