Higher Order Flattening

  • Roman Leshchinskiy
  • Manuel M. T. Chakravarty
  • Gabriele Keller
Part of the Lecture Notes in Computer Science book series (LNCS, volume 3992)

Abstract

We extend the flattening transformation, which turns nested into flat data parallelism, to the full higher-order case, including lambda abstractions and data parallel arrays of functions. Our central observation is that flattening needs to transform the closures used to represent functional values. Thus, we use closure conversion before flattening and introduce array closures to represent arrays of functional values.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    Blelloch, G.E.: Vector Models for Data-Parallel Computing. MIT Press, Cambridge (1990)Google Scholar
  2. 2.
    Blelloch, G.E.: Programming parallel algorithms. CACM 39(3), 85–97 (1996)Google Scholar
  3. 3.
    Chakravarty, M.M.T., Keller, G.: More types for nested data parallel programming. In: Wadler, P. (ed.) 5th ACM SIGPLAN Intl. Conf. on Functional Programming (ICFP 2000), pp. 94–105. ACM Press, New York (2000)CrossRefGoogle Scholar
  4. 4.
    Chakravarty, M.M.T., Keller, G.: An approach to fast arrays in Haskell. In: Jeuring, J., Jones, S.L.P. (eds.) AFP 2002. LNCS, vol. 2638. Springer, Heidelberg (2003)CrossRefGoogle Scholar
  5. 5.
    Chakravarty, M.M.T., Keller, G., Lechtchinsky, R., Pfannenstiel, W.: Nepal - nested data parallelism in haskell. In: Sakellariou, R., Keane, J.A., Gurd, J.R., Freeman, L. (eds.) Euro-Par 2001. LNCS, vol. 2150, pp. 524–534. Springer, Heidelberg (2001)CrossRefGoogle Scholar
  6. 6.
    Leshchinskiy, R.: Higher-Order Nested Data Parallelism: Semantics and Implementation. PhD thesis, Technische Universität Berlin (2005)Google Scholar
  7. 7.
    Minamide, Y., Morrisett, G., Harper, R.: Typed closure conversion. In: POPL 1996: Proc. of the 23rd ACM SIGPLAN-SIGACT Sym. on Principles of Programming Languages, pp. 271–283. ACM Press, New York (1996)CrossRefGoogle Scholar
  8. 8.
    Wadler, P.: Theorems for free! In: FPCA 1989: Proceedings 4th International Conference on Functional Programming Languages and Computer Architecture, pp. 347–359. ACM Press, New York (1989)CrossRefGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2006

Authors and Affiliations

  • Roman Leshchinskiy
    • 1
  • Manuel M. T. Chakravarty
    • 1
  • Gabriele Keller
    • 1
  1. 1.School of Computer Science and Engineering, Programming Languages and SystemsUniversity of New South WalesAustralia

Personalised recommendations