Skip to main content

Loop Shifting for Loop Compaction

  • Conference paper
  • First Online:
Languages and Compilers for Parallel Computing (LCPC 1999)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 1863))

Abstract

The idea of decomposed software pipelining is to decouple the software pipelining problem into a cyclic scheduling problem without resource constraints and an acyclic scheduling problem with resource constraints. In terms of loop transformation and code motion, the technique can be formulated as a combination of loop shifting and loop compaction. Loop shifting amounts to move statements between iterations thereby changing some loop independent dependences into loop carried dependences and vice versa. Then, loop compaction schedules the body of the loop considering only loop independent dependences, but taking into account the details of the target architecture. In this paper, we show how loop shifting can be optimized so as to minimize both the length of the critical path and the number of dependences for loop compaction. Both problems (and the combination) are polynomially solvable with fast graph algorithms, the first one by using an algorithm due to Leiserson and Saxe, the second one by designing a variant of minimum-cost flow algorithms.

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. Alexander Aiken and Alexandru Nicolau. Perfect pipelining; a new loop optimization technique. In 1988 European Symposium on Programming, volume 300 of Lecture Notes in Computer Science, pages 221–235. Springer Verlag, 1988.

    Google Scholar 

  2. Vicki H. Allan, Reese B. Jones, Randall M. Lee, and Stephen J. Allan. Software pipelining. ACM Computing Surveys, 27(3):367–432, September 1995.

    Google Scholar 

  3. Tsing-Fa Lee Allen, C.-H Wu Wei-Jeng Chen, Wei-Kai Cheng, and Youn-Long Lin. On the relationship between sequential logic retiming and loop folding. In Proceedings of the SASIMI’93, pages 384–393, Nara, Japan, October 1993.

    Google Scholar 

  4. P.Y. Calland, A. Darte, and Y. Robert. Circuit retiming applied to decomposed software pipelining. IEEE Transactions on Parallel and Distributed Systems, 9(1):24–35, January 1998.

    Google Scholar 

  5. L.-F. Chao, A. LaPaugh, and E. Sha. Rotation scheduling: a loop pipelining algorithm. In 30th ACM/IEEE design automation conference, pages 566–572, 1993.

    Google Scholar 

  6. E. G. Coffman. Computer and job-shop scheduling theory. John Wiley, 1976.

    Google Scholar 

  7. Alain Darte and Guillaume Huard. Loop shifting for loop compaction. Technical Report RR1999-29, LIP, ENS-Lyon, France, May 1999.

    Google Scholar 

  8. Alain Darte, Georges-André Silber, and Frédéric Vivien. Combining retiming and scheduling techniques for loop parallelization and loop tiling. Parallel Processing Letters, 7(4):379–392, 1997.

    Article  Google Scholar 

  9. Carole Dulong. The IA-64 architecture at work. Computer, 31(7):24–32, July 1998.

    Google Scholar 

  10. F. Gasperoni and U. Schwiegelshohn. Generating close to optimum loop schedules on parallel processors. Parallel Processing Letters, 4(4):391–403, 1994.

    Article  MathSciNet  Google Scholar 

  11. M. Gondran and M. Minoux. Graphs and Algorithms. John Wiley, 1984.

    Google Scholar 

  12. C. Hanen and A. Munier. Cyclic scheduling on parallel processors: an overview. In P. Chrétienne, E. G. Coffman, J. K. Lenstra, and Z. Liu, editors, Scheduling Theory and its Applications. John Wiley & Sons Ltd, 1995.

    Google Scholar 

  13. John L. Hennessy and David A. Patterson. Computer architecture: a quantitative approach (2nd edition). Morgan-Kaufmann, 1996.

    Google Scholar 

  14. R. A. Huff. Lifetime-sensitive modulo scheduling. In Conference on programming language design and implementation (PLDI’93), pages 258–267. ACM, 1993.

    Google Scholar 

  15. Suneel Jain. Circular scheduling. In Conference on programming language design and implementation (PLDI’91), pages 219–228. ACM, 1991.

    Google Scholar 

  16. Monica S. Lam. Software pipelining; an effective scheduling technique for VLIW machines. In SIGPLAN’88 Conference on Programming Language, Design and Implementation, pages 318–328, Atlanta, GA, 1988. ACM Press.

    Google Scholar 

  17. C.E. Leiserson and J.B. Saxe. Retiming synchronous circuitry. Algorithmica, 6(1):5–35, 1991.

    Article  MATH  MathSciNet  Google Scholar 

  18. J. Llosa, A. González, E. Ayguadé, and M. Valero. Swing modulo scheduling: a lifetime-sensitive approach. In Conference on Parallel Architectures and Compilation Techniques (PACT’96), Boston, MA, 1996. IEEE Computer Society Press.

    Google Scholar 

  19. Soo-Mook Moon and Kemal Ebcioğlu. An efficient resource-constrained global scheduling technique for superscalar and VLIW processors. In 25th annual international symposium on Microarchitecture, pages 55–71, 1992.

    Google Scholar 

  20. Andreas I. Moshovos, Scott E. Breach, T.N. Vijaykumar, and Gurindar S. Sohi. Dynamic speculation and synchronization of data dependences. In 24th International Symposium on Computer Architecture (ISCA’97), pages 181–193, Jun 1997.

    Google Scholar 

  21. M. Rajagopalan and V. H. Allan. Specification of software pipelining using petri nets. International Journal of Parallel Programming, 22(3):273–301, 1994.

    Article  Google Scholar 

  22. B. R. Rau. Iterative modulo scheduling: an algorithm for software pipelining. In 27th annual international symposium on Microarchitecture, pages 63–74, 1994.

    Google Scholar 

  23. B. R. Rau. Iterative modulo scheduling. International Journal of Parallel Programming, 24(1):3–64, 1996.

    MathSciNet  Google Scholar 

  24. B. R. Rau and C. D. Glaeser. Some scheduling techniques and an easily schedulable horizontal architecture for high performance scientific computing. In Proceedings of the Fourteenth Annual Workshop of Microprogramming, pages 183–198, October 1981.

    Google Scholar 

  25. U. Schwiegelshohn, F. Gasperoni, and K. Ebcioğlu. On optimal parallelization of arbitrary loops. Journal of Parallel and Distributed Computing, 11:130–134, 1991.

    Article  Google Scholar 

  26. Georges-André Silber and Alain Darte. The Nestor library: A tool for implementing Fortran source to source transformations. In High Performance Computing and Networking (HPCN’99), volume 1593 of Lecture Notes in Computer Science, pages 653–662. Springer Verlag, April 1999.

    Chapter  Google Scholar 

  27. J. Wang, C. Eisenbeis, M. Jourdan, and B. Su. Decomposed software pipelining. International Journal of Parallel Programming, 22(3):351–373, 1994.

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2000 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Darte, A., Huard, G. (2000). Loop Shifting for Loop Compaction. In: Carter, L., Ferrante, J. (eds) Languages and Compilers for Parallel Computing. LCPC 1999. Lecture Notes in Computer Science, vol 1863. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-44905-1_26

Download citation

  • DOI: https://doi.org/10.1007/3-540-44905-1_26

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-67858-8

  • Online ISBN: 978-3-540-44905-8

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics