Space profiling for parallel functional programs

This paper presents a semantic space profiler for parallel functional programs. Building on previous work in sequential profiling, our tools help programmers to relate runtime resource use back to program source code. Unlike many profiling tools, our profiler is based on a cost semantics. This provides a means to reason about performance without requiring a detailed understanding of the compiler or runtime system. It also provides a specification for language implementers. This is critical in that it enables us to separate cleanly the performance of the application from that of the language implementation. Some aspects of the implementation can have significant effects on performance. Our cost semantics enables programmers to understand the impact of different scheduling policies while hiding many of the details of their implementations. We show applications where the choice of scheduling policy has asymptotic effects on space use. We explain these use patterns through a demonstration of our tools. We also validate our methodology by observing similar performance in our implementation of a parallel extension of Standard ML.

[1]  Simon L. Peyton Jones,et al.  Profiling Lazy Functional Programs , 1992, Functional Programming.

[2]  Guy E. Blelloch,et al.  A provable time and space efficient implementation of NESL , 1996, ICFP '96.

[3]  Guy E. Blelloch,et al.  Implementation of a portable nested data-parallel language , 1993, PPOPP '93.

[4]  Hans-Wolfgang Loidl,et al.  A Sized Time System for a Parallel Functional Language , 1996 .

[5]  Charles E. Leiserson,et al.  Space-efficient scheduling of multithreaded computations , 1993, SIAM J. Comput..

[6]  Andrew W. Appel,et al.  Space-efficient closure representations , 1994, LFP '94.

[7]  Guy E. Blelloch,et al.  A parallel, real-time garbage collector , 2001, PLDI '01.

[8]  Colin Runciman,et al.  An Interactive Approach to Profiling Parallel Functional Programs , 1998, IFL.

[9]  David Sands,et al.  A Foundation for Space-Safe Transformations of Call-by-Need Programs , 1999, HOOTS.

[10]  Stephen Weeks,et al.  Whole-program compilation in MLton , 2006, ML '06.

[11]  Guy E. Blelloch,et al.  Space profiling for parallel functional programs , 2010, Journal of Functional Programming.

[12]  Simon L. Peyton Jones,et al.  Time and space profiling for non-strict, higher-order functional languages , 1995, POPL '95.

[13]  Colin Runciman,et al.  Profiling Parallel Functional Computations (Without Parallel Machines) , 1993, Functional Programming.

[14]  Robert Jonathan Ennals,et al.  Adaptive evaluation of non-strict programs , 2004 .

[15]  Guy E. Blelloch,et al.  Provably efficient scheduling for languages with fine-grained parallelism , 1995, SPAA '95.

[16]  Shail Aditya,et al.  Semantics of pH: A parallel dialect of Haskell , 1995 .

[17]  Colin Runciman,et al.  Heap profiling of lazy functional programs , 1993, Journal of Functional Programming.

[18]  John H. Reppy,et al.  Status report: the manticore project , 2007, ML '07.

[19]  Manuel M. T. Chakravarty,et al.  More types for nested data parallel programming , 2000, ICFP '00.

[20]  Guy E. Blelloch,et al.  Implementation of a portable nested data-parallel language , 1993, PPOPP '93.

[21]  Murray Cole,et al.  A Monadic Calculus for Parallel Costing of a Functional Language of Arrays , 1997, Euro-Par.

[22]  Sylvain Conchon,et al.  Jocaml: mobile agents for Objective-Caml , 1999, Proceedings. First and Third International Symposium on Agent Systems Applications, and Mobile Agents.

[23]  John H. Reppy,et al.  Concurrent programming in ML , 1999 .

[24]  Niklas Röjemo,et al.  Lag, drag, void and use—heap profiling and space-efficient compilation revisited , 1996, ICFP '96.

[25]  Keshav Pingali,et al.  I-structures: data structures for parallel computing , 1986, Graph Reduction.

[26]  Rita Loogen,et al.  Automatic Skeletons in Template Haskell , 2003, Parallel Process. Lett..

[27]  Hans-Wolfgang Loidl,et al.  Visualising Granularity in Parallel Programs: A Graphical Winnowing System for Haskell , 1995 .