Mapping deviation: a technique to adapt or to guard loop transformation intuitions for legality

Parallel architectures are now omnipresent in mainstream electronic devices and exploiting them efficiently is a challenge for all developers. Hence, they need the support of languages, libraries and tools to assist them in the optimization or parallelization task. Compilers can provide a major help by automating this work. However they are very fragile black-boxes. A compiler may take a bad optimization decision because of imprecise heuristics or may turn off an optimization because of imprecise analyses, without providing much control or feedback to the end user. To address this issue, we introduce mapping deviation, a new compiler technique that aims at providing a useful feedback on the semantics of a given program restructuring. Starting from a transformation intuition a user or a compiler wants to apply, our algorithm studies its correctness and can suggest changes or conditions to make it possible rather than being limited to the classical go/no-go answer. This algorithm builds on state-of-the-art polyhedral representation of programs and provides a high flexibility. We present two example applications of this technique: improving semi-automatic optimization tools for programmers and automatically designing runtime tests to check the correctness of a transformation for compilers.

[1]  Paul Feautrier,et al.  Automatic Storage Management for Parallel Programs , 1998, Parallel Comput..

[2]  Johannes Doerfert Saarbrücken,et al.  SPolly : Speculative Optimizations in the Polyhedral Model , 2012 .

[3]  Albert Cohen,et al.  GRAPHITE Two Years After First Lessons Learned From Real-World Polyhedral Compilation , 2010 .

[4]  Sanjay V. Rajopadhye,et al.  Generation of Efficient Nested Loops from Polyhedra , 2000, International Journal of Parallel Programming.

[5]  Chau-Wen Tseng,et al.  Improving data locality with loop transformations , 1996, TOPL.

[6]  Francky Catthoor,et al.  Polyhedral parallel code generation for CUDA , 2013, TACO.

[7]  Hongbin Zheng,et al.  Polly – Polyhedral optimization in LLVM , 2012 .

[8]  Corinne Ancourt,et al.  Minimal Data Dependence Abstractions for Loop Transformations , 1994, LCPC.

[9]  Paul Feautrier,et al.  Adjusting a Program Transformation for Legality , 2005, Parallel Process. Lett..

[10]  Uday Bondhugula,et al.  A practical automatic polyhedral parallelizer and locality optimizer , 2008, PLDI '08.

[11]  Uday Bondhugula,et al.  Loop transformations: convexity, pruning and optimization , 2011, POPL '11.

[12]  Uday Bondhugula,et al.  Combined iterative and model-driven optimization in an automatic parallelization framework , 2010, 2010 ACM/IEEE International Conference for High Performance Computing, Networking, Storage and Analysis.

[13]  Corinne Ancourt,et al.  Minimal data dependence abstractions for loop transformations: Extended version , 1995, International Journal of Parallel Programming.

[14]  Albert Cohen,et al.  Violated dependence analysis , 2006, ICS '06.

[15]  Mary W. Hall,et al.  Non-affine Extensions to Polyhedral Code Generation , 2014, CGO '14.

[16]  Cédric Bastoul,et al.  Code generation in the polyhedral model is easier than you think , 2004, Proceedings. 13th International Conference on Parallel Architecture and Compilation Techniques, 2004. PACT 2004..

[17]  Wolfgang E. Nagel,et al.  Optimizing Cache Access: A Tool for Source-to-Source Transformations and Real-Life Compiler Tests , 2004, Euro-Par.

[18]  Frédéric Vivien,et al.  Combining Retiming and Scheduling Techniques for Loop Parallelization and Loop Tiling , 1997, Parallel Process. Lett..

[19]  Paul Feautrier,et al.  Array expansion , 1988, ICS '88.

[20]  J. Ramanujam,et al.  A framework for enhancing data reuse via associative reordering , 2014, PLDI.

[21]  François Irigoin Dependence Abstractions , 2011, Encyclopedia of Parallel Computing.

[22]  Keshav Pingali,et al.  A singular loop transformation framework based on non-singular matrices , 1992, International Journal of Parallel Programming.

[23]  David Parello,et al.  Semi-Automatic Composition of Loop Transformations for Deep Parallelism and Memory Hierarchies , 2006, International Journal of Parallel Programming.

[24]  Martin Griebl,et al.  Index Set Splitting , 2000, International Journal of Parallel Programming.

[25]  Paul Feautrier,et al.  Some efficient solutions to the affine scheduling problem. I. One-dimensional time , 1992, International Journal of Parallel Programming.

[26]  Patrice Quinton,et al.  Efficient nested loop pipelining in high level synthesis using polyhedral bubble insertion , 2011, 2011 International Conference on Field-Programmable Technology.

[27]  Ken Kennedy,et al.  Automatic translation of FORTRAN programs to vector form , 1987, TOPL.

[28]  W. Pugh,et al.  A framework for unifying reordering transformations , 1993 .

[29]  Cédric Bastoul,et al.  Opening polyhedral compiler's black box , 2016, 2016 IEEE/ACM International Symposium on Code Generation and Optimization (CGO).

[30]  Martin Griebl,et al.  Code generation in the polytope model , 1998, Proceedings. 1998 International Conference on Parallel Architectures and Compilation Techniques (Cat. No.98EX192).

[31]  Albert Cohen,et al.  The Polyhedral Model Is More Widely Applicable Than You Think , 2010, CC.

[32]  Albert Cohen,et al.  Automatic Correction of Loop Transformations , 2007, 16th International Conference on Parallel Architecture and Compilation Techniques (PACT 2007).

[33]  Monica S. Lam,et al.  Improving parallelism and data locality with affine partitioning , 2001 .

[34]  Albert Cohen,et al.  Iterative optimization in the polyhedral model: part ii, multidimensional time , 2008, PLDI '08.

[35]  Cédric Bastoul,et al.  Clint: A direct manipulation tool for parallelizing compute-intensive program parts , 2014, 2014 IEEE Symposium on Visual Languages and Human-Centric Computing (VL/HCC).

[36]  P. Feautrier Parametric integer programming , 1988 .

[37]  David A. Padua,et al.  A Language for the Compact Representation of Multiple Program Versions , 2005, LCPC.

[38]  Paul Feautrier,et al.  Polyhedron Model , 2011, Encyclopedia of Parallel Computing.

[39]  Monica S. Lam,et al.  A data locality optimizing algorithm , 1991, PLDI '91.

[40]  Sven Verdoolaege,et al.  isl: An Integer Set Library for the Polyhedral Model , 2010, ICMS.