Skip to main content

Paraphrasing: Generating Parallel Programs Using Refactoring

  • Chapter
Formal Methods for Components and Objects (FMCO 2011)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 7542))

Included in the following conference series:

Abstract

Refactoring is the process of changing the structure of a program without changing its behaviour. Refactoring has so far only really been deployed effectively for sequential programs. However, with the increased availability of multicore (and, soon, manycore) systems, refactoring can play an important role in helping both expert and non-expert parallel programmers structure and implement their parallel programs. This paper describes the design of a new refactoring tool that is aimed at increasing the programmability of parallel systems. To motivate our design, we refactor a number of examples in C, C++ and Erlang into good parallel implementations, using a set of formal pattern rewrite rules.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Netflix Prize Forum/Grand Prize Award (September 2009), http://www.netflixprize.com/community/viewtopic.php?id=1537

  2. Aldinucci, M., Danelutto, M.: Stream Parallel Skeleton Optimization. In: Proc. of PDCS: Intl. Conference on Parallel and Distributed Computing and Systems, pp. 955–962. IASTED, ACTA Press, Cambridge, Massachusetts (1999)

    Google Scholar 

  3. Aldinucci, M., Danelutto, M., Kilpatrick, P., Meneghin, M., Torquati, M.: Accelerating Code on Multi-cores with FastFlow. In: Jeannot, E., Namyst, R., Roman, J. (eds.) Euro-Par 2011, Part II. LNCS, vol. 6853, pp. 170–181. Springer, Heidelberg (2011)

    Chapter  Google Scholar 

  4. Backus, J.: Can Programming be Liberated from the von Neumann Style? Communications of the ACM 21(8), 613–641 (1978)

    Article  MathSciNet  MATH  Google Scholar 

  5. Benkner, S., Pllana, S., Träff, J.L., Tsigas, P., Dolinsky, U., Augonnet, C., Bachmayer, B., Kessler, C.W., Moloney, D., Osipov, V.: PEPPHER: Efficient and Productive Usage of Hybrid Computing Systems. IEEE Micro 31(5), 28–41 (2011)

    Article  Google Scholar 

  6. Bird, R.S.: Lectures on Constructive Functional Programming. In: Broy, M. (ed.) Constructive Methods in Computer Science. NATO ASI Series F, vol. 55, pp. 151–218. Springer (1988); Also available as Technical Monograph PRG-69, from the Programming Research Group, Oxford University

    Google Scholar 

  7. Bravenboer, M., Kalleberg, K.T., Vermaas, R., Visser, E.: Stratego/xt 0.17. A Language and Toolset for Program Transformation. Sci. Comput. Program. 72(1-2), 52–70 (2008)

    Article  MathSciNet  Google Scholar 

  8. Brown, C., Li, H., Thompson, S.: An Expression Processor: A Case Study in Refactoring Haskell Programs. In: Page, R., Horváth, Z., Zsók, V. (eds.) TFP 2010. LNCS, vol. 6546, pp. 31–49. Springer, Heidelberg (2011)

    Chapter  Google Scholar 

  9. Brown, C., Loidl, H.-W., Hammond, K.: ParaForming: Forming Parallel Haskell Programs Using Novel Refactoring Techniques. In: Peña, R., Page, R. (eds.) TFP 2011. LNCS, vol. 7193, pp. 82–97. Springer, Heidelberg (2012)

    Chapter  Google Scholar 

  10. Burstall, R.M., Darlington, J.: A Transformation System for Developing Recursive Programs. J. ACM 24(1), 44–67 (1977)

    Article  MathSciNet  MATH  Google Scholar 

  11. Cesarini, F., Thompson, S.: ERLANG Programming, 1st edn. O’Reilly Media, Inc. (2009)

    Google Scholar 

  12. Dig, D.: A Refactoring Approach to Parallelism. IEEE Softw. 28, 17–22 (2011)

    Article  Google Scholar 

  13. Gemulla, R., Haas, P.J., Sismanis, Y., Teflioudi, C., Makari, F.: Large-Scale Matrix Factorization with Distributed Stochastic Gradient Descent. In: NIPS 2011 Workshop on Big Learning, Sierra Nevada, Spain (December 2011)

    Google Scholar 

  14. Hammond, K., Aldinucci, M., Brown, C., Cesarini, F., Danelutto, M., González-Vélez, H., Kilpatrick, P., Keller, R., Rossbory, M., Shainer, G.: The ParaPhrase: Project: Parallel Patterns for Adaptive Heterogeneous Multicore Systems. In: Beckert, B., de Boer, F., Bonsangue, M., Damiani, F. (eds.) FMCO 2011. LNCS, vol. 7542, pp. 218–236. Springer, Heidelberg (2012)

    Google Scholar 

  15. Klusik, U., Loogen, R., Priebe, S., Rubio, F.: Implementation Skeletons in Eden: Low-Effort Parallel Programming. In: Mohnen, M., Koopman, P. (eds.) IFL 2000. LNCS, vol. 2011, pp. 71–88. Springer, Heidelberg (2001)

    Chapter  Google Scholar 

  16. Koren, Y., Bell, R., Volinsky, C.: Matrix Factorization Techniques for Recommender Systems. IEEE Computer 42(8), 30–37 (2009)

    Article  Google Scholar 

  17. Li, H., Thompson, S.: A Comparative Study of Refactoring Haskell and Erlang Programs. In: SCAM 2006, pp. 197–206. IEEE (September 2006)

    Google Scholar 

  18. Li, H., Thompson, S.: A Domain-Specific Language for Scripting Refactorings in Erlang. Technical Report 5-11, University of Kent (October 2011)

    Google Scholar 

  19. Li, H., Thompson, S.: A User-extensible Refactoring Tool for Erlang Programs. Technical Report 4-11, University of Kent (October 2011)

    Google Scholar 

  20. Matsuzaki, K., Iwasaki, H., Emoto, K., Hu, Z.: A Library of Constructive Skeletons for Sequential Style of Parallel Programming. In: Proceedings of the 1st International Conference on Scalable Information Systems, InfoScale 2006. ACM, New York (2006)

    Google Scholar 

  21. Mens, T., Tourwé, T.: A Survey of Software Refactoring. IEEE Trans. Softw. Eng. 30(2), 126–139 (2004)

    Article  Google Scholar 

  22. Moore, G.E.: Cramming more components onto integrated circuits. In: Readings in Computer Architecture, pp. 56–59. Morgan Kaufmann Publishers Inc., San Francisco (2000)

    Google Scholar 

  23. Nugteren, C., Corporaal, H., Mesman, B.: Skeleton-based Automatic Parallelization of Image Processing Algorithms for GPUs. In: ICSAMOS 2011, pp. 25–32 (2011)

    Google Scholar 

  24. Opdyke, W.F.: Refactoring Object-Oriented Frameworks. PhD thesis, Department of Computer Science, University of Illinois at Urbana-Champaign, Champaign, IL, USA (1992)

    Google Scholar 

  25. Padioleau, Y., Lawall, J.L., Muller, G.: SmPL: A Domain-Specific Language for Specifying Collateral evolutions in Linux device drivers. In: International ERCIM Workshop on Software Evolution, Lille, France (April 2006)

    Google Scholar 

  26. Partsch, H., Steinbruggen, R.: Program Transformation Systems. ACM Comput. Surv. 15(3), 199–236 (1983)

    Article  MathSciNet  Google Scholar 

  27. Sankaran, S., Squyres, J.M., Barrett, B., Lumsdaine, A., Duell, J., Hargrove, P., Roman, E.: The LAM/MPI Checkpoint/Restart Framework: System-Initiated Checkpointing. International Journal of High Performance Computing Applications 19(4), 479–493 (2005)

    Article  Google Scholar 

  28. Skillicorn, D.B.: The Bird-Meertens Formalism as a Parallel Model. In: Software for Parallel Computation. NATO ASI Series F, vol. 106, pp. 120–133. Springer (1993)

    Google Scholar 

  29. Wloka, J., Sridharan, M., Tip, F.: Refactoring for Reentrancy. In: ESEC/FSE 2009, pp. 173–182. ACM, Amsterdam (2009)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2013 Springer-Verlag Berlin Heidelberg

About this chapter

Cite this chapter

Brown, C., Hammond, K., Danelutto, M., Kilpatrick, P., Schöner, H., Breddin, T. (2013). Paraphrasing: Generating Parallel Programs Using Refactoring. In: Beckert, B., Damiani, F., de Boer, F.S., Bonsangue, M.M. (eds) Formal Methods for Components and Objects. FMCO 2011. Lecture Notes in Computer Science, vol 7542. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-35887-6_13

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-35887-6_13

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-35886-9

  • Online ISBN: 978-3-642-35887-6

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics