Advertisement

Repeating History: Execution Replay for Parallel Haskell Programs

  • Henrique Ferreiro
  • Vladimir Janjic
  • Laura M. Castro
  • Kevin Hammond
Part of the Lecture Notes in Computer Science book series (LNCS, volume 7829)

Abstract

Parallel profiling tools, such as ThreadScope for Parallel Haskell, allow programmers to obtain information about the performance of their parallel programs. However, the information they provide is not always sufficiently detailed to precisely pinpoint the cause of some performance problems. Often, this is because the cost of obtaining that information would be prohibitive for a complete program execution. In this paper, we adapt the well-known technique of execution replay to make it possible to simulate a previous run of a program. We ensure that the non-deterministic parallel behaviour of the Parallel Haskell application is properly emulated while its deterministic functionality is unmodified. In this way, we can gather additional data about the behaviour of a parallel program by replaying some parts of it with more detailed profiling information. We exploit this ability to identify performance bottlenecks in a quicksort implementation, and to derive a version that achieves an 82% speedup over a naive parallelisation.

Keywords

Parallel Program Garbage Collection Program Execution Thread Block Runtime System 
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.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    Berthold, J., Loogen, R.: Visualizing Parallel Functional Program Runs: Case Studies with the Eden Trace Viewer. In: Parallel Computing: Architectures, Algorithms and Applications. Advances in Parallel Computing, vol. 15, pp. 121–128. IOS Press (2008)Google Scholar
  2. 2.
    Cornelis, F., Georges, A., Christiaens, M., Ronsse, M., Ghesquiere, T., De Bosschere, K.: A Taxonomy of Execution Replay Systems. In: Proc. of the Intl. Conf. on Advances in Infrastructure for Electronic Business, Education, Science, Medicine, and Mobile Technologies on the Internet (2003)Google Scholar
  3. 3.
    Hammond, K., Loidl, H.W., Trinder, P.: Parallel Cost Centre Profiling. In: Proc. of the Glasgow Workshop on Functional Programming, Ullapool, Scotland (1997)Google Scholar
  4. 4.
    Hughes, J., Sheeran, M.: Teaching Parallel Functional Programming at Chalmers. In: Draft Proc. TFPIE 2012 (2012)Google Scholar
  5. 5.
    Itskova, E.: Echo: A Deterministic Record/Replay Framework for Debugging Multithreaded Applications. Master’s thesis, Imperial College, London (2006)Google Scholar
  6. 6.
    Jones Jr., D., Marlow, S., Singh, S.: Parallel Performance Tuning for Haskell. In: Proc. Haskell 2009, pp. 81–92. ACM (2009)Google Scholar
  7. 7.
    Laadan, O., Viennot, N., Nieh, J.: Transparent, lightweight application execution replay on commodity multiprocessor operating systems. In: Proc. SIGMETRICS 2010, pp. 155–166. ACM (2010)Google Scholar
  8. 8.
    Lee, D., Said, M., Narayanasamy, S., Yang, Z., Pereira, C.: Offline symbolic analysis for multi-processor execution replay. In: Proc. MICRO, vol. 42, pp. 564–575. ACM (2009)Google Scholar
  9. 9.
    Loidl, H.W.: Granularity in Large-Scale Parallel Functional Programming. Ph.D. thesis, Department of Computing Science, University of Glasgow (1998)Google Scholar
  10. 10.
    Marlow, S.: Haskell 2010. Language Report (2010), http://www.haskell.org/onlinereport/haskell2010
  11. 11.
    Marlow, S., Peyton Jones, S., Singh, S.: Runtime Support for Multicore Haskell. In: Proc. ICFP 2009, pp. 65–78. ACM (2009)Google Scholar
  12. 12.
    Mathur, W., Cook, J.: Toward Accurate Performance Evaluation using Hardware Counters. In: Proc. of the Applications for a Changing World, ITEA Modeling & Simulation Workshop (2003)Google Scholar
  13. 13.
    Peyton Jones, S.L., Hall, C.V., Hammond, K., Partain, W., Wadler, P.: The Glasgow Haskell compiler: A Technical Overview. In: Proc. UK Joint Framework for Information Technology (JFIT) Technical Conf. (1993)Google Scholar
  14. 14.
    Ronsse, M., De Bosschere, K., Chassin de Kergommeaux, J.: Execution Replay and Debugging. arXiv:cs/0011006 (2000)Google Scholar
  15. 15.
    Trinder, P.W., Hammond, K., Loidl, H.W., Peyton Jones, S.: Algorithms + Strategy = Parallelism. Journal of Functional Programming 8(1), 23–60 (1998)MathSciNetzbMATHCrossRefGoogle Scholar
  16. 16.
    Trinder, P.W., Hammond, K., Mattson Jr., J.S., Partridge, A.S., Peyton Jones, S.: GUM: A Portable Parallel Implementation of Haskell. In: Proc. PLDI 1996, pp. 79–88. ACM (1996)Google Scholar
  17. 17.
    Zaparanuks, D., Jovic, M., Hauswirth, M.: Accuracy of performance counter measurements. In: Proc. ISPASS 2009, pp. 23–32. IEEE (2009)Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2013

Authors and Affiliations

  • Henrique Ferreiro
    • 1
  • Vladimir Janjic
    • 2
  • Laura M. Castro
    • 1
  • Kevin Hammond
    • 2
  1. 1.Department of Computer ScienceUniversity of A CoruñaSpain
  2. 2.School of Computer ScienceUniversity of St AndrewsUnited Kingdom

Personalised recommendations