skip to main content
research-article

Exploration of compiler optimization sequences using clustering-based selection

Published:12 June 2014Publication History
Skip Abstract Section

Abstract

Due to the large number of optimizations provided in modern compilers and to compiler optimization specific opportunities, a Design Space Exploration (DSE) is necessary to search for the best sequence of compiler optimizations for a given code fragment (e.g., function). As this exploration is a complex and time consuming task, in this paper we present DSE strategies to select optimization sequences to both improve the performance of each function and reduce the exploration time. The DSE is based on a clustering approach which groups functions with similarities and then explore the reduced search space provided by the optimizations previously suggested for the functions in each group. The identification of similarities between functions uses a data mining method which is applied to a symbolic code representation of the source code. The DSE process uses the reduced set identified by clustering in two ways: as the design space or as the initial configuration. In both ways, the adoption of a pre-selection based on clustering allows the use of simple and fast DSE algorithms. Our experiments for evaluating the effectiveness of the proposed approach address the exploration of compiler optimization sequences considering 49 compilation passes and targeting a Xilinx MicroBlaze processor, and were performed aiming performance improvements for 41 functions. Experimental results reveal that the use of our new clustering-based DSE approach achieved a significant reduction on the total exploration time of the search space (18x over a Genetic Algorithm approach for DSE) at the same time that important performance speedups (43% over the baseline) were obtained by the optimized codes.

References

  1. S. Kulkarni and J. Cavazos, "Mitigating the compiler optimization phase-ordering problem using machine learning", ACM Int. Conf. on Object Oriented Programming Systems Languages and Applications (OOPSLA'12), pp.147--162, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. L. Almagor , et al., "Finding effective compilation sequences", 2004 ACM SIGPLAN/SIGBED Conf. on Languages, Compilers, and Tools for Embedded Systems, vol. 39, pp. 231--239, Jun. 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. K. Hoste and L. Eeckhout, "Cole: compiler optimization level exploration", 6th Int. Symp. on Code Generation and Optimization (CGO'08), pp.165--174, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. A. Sanches and J. M. P. Cardoso, "On Identifying Patterns in Code Repositories to Assist the Generation of Hardware Templates", 20th Int. Conf. on Field Programmable Logic and Applications (FPL'10), pp. 267--270, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. A. Sanches, J. M. P. Cardoso and A. C. B. Delbem, "Identifying Merge-Beneficial Software Kernels for Hardware Implementation", Int. conf. on Reconfigurable Computing and FPGAs (ReConFig'11), pp.74--79, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. J. M. P. Cardoso et al., Compilation and Synthesis for Embedded Reconfigurable Systems: An Aspect-Oriented Approach. Springer, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. "ACE CoSy Compiler Development System", Available: http://www.ace.nl/compiler/cosy.html, (accessed in 18/10/2012).Google ScholarGoogle Scholar
  8. J. M. P. Cardoso, et al., "LARA: an aspect-oriented programming language for embedded systems", 11th ACM Int. Conf. on Aspect-Oriented Software Development (AOSD'12), pp.179--190, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. A. R. Cilibrasi and A. P. Vitanyi, "Clustering by compression", IEEE Trans. Information Theory., vol. 51, no. 4, pp. 1523--1545, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. J. Felsenstein, Inferring phylogenies. Sinauer Associates, Inc, 2003.Google ScholarGoogle Scholar
  11. D. E. Goldberg, "Genetic Algorithms in Search, Optimization and Machine Learning", 1st ed., Addison-Wesley Longman, 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Q. Huang, et al., "The Effect of Compiler Optimizations on High-Level Synthesis for FPGAs", IEEE Int. Symp. on Field-Programmable Custom Computing Machines (FCCM'13), pp. 89--96, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. T. Wheeler, and J. Kececioglu, "Multiple alignment by aligning alignments", 15th ISCB Conf. on Intelligent Systems for Molecular Biology, Bioinformatics, vol. 23, no. 13, pp. i559-i568, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. C. K. Roy, J. R. Cordy, and R. Koschke, "Comparison and Evaluation of Code Clone Detection Techniques and Tools: A Qualitative Approach", Science of Computer Programming., vol. 74, no. 7, pp. 470--495, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. M. Li and P. M. B. Vitanyi, An introduction to Kolmogorov complexity and its applications. 2nd ed. Springer-Verlag, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. M. Newman, Networks: An Introduction. Oxford Univ. Press, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Texas Instruments, "TMS320C64x Image/Video Processing Library", 2003.Google ScholarGoogle Scholar
  18. Texas Instruments, "TMS320C64x DSP Library: Programmer's Reference", 2003.Google ScholarGoogle Scholar
  19. M. R. Guthaus, et al., "MiBench: A free, commercially representative embedded benchmark suite", IEEE Int. Workshop of the Workload Characterization (WWC-4), pp.3--14, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. P. A. Kulkarni, D. B. Whalley and G. S. Tyson, "Evaluating heuristic optimization phase order search algorithms", IEEE Int. Symp. on Code Generation and Optimization (CGO'07), pp.157--169, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Michael R. Jantz and Prasad A. Kulkarni, "Performance potential of optimization phase selection during dynamic JIT compilation", 9th ACM SIGPLAN/SIGOPS Int. Conf. on Virtual Execution Environments (VEE '13), pp.131--142, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. J. M. P. Cardoso, P. Diniz, and M. Weinhardt, "Compiling for Reconfigurable Computing: A Survey", ACM Computing Surveys, vol. 42, no.4, pp.1--65, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. K. D. Cooper, et al., "Exploring the structure of the space of compilation sequences using randomized search algorithms", Journal of Supercomputing, vol. 36, no. 2, pp.135--151, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. E. Zitzler and M. Laumanns and L. Thiele, "SPEA2: Improving the Strength Pareto Evolutionary Algorithm", Swiss Federal Inst. of Technology - Computer Engineering and Networks Lab. (technical report), 21 pages, 2001.Google ScholarGoogle Scholar
  25. P. A. Kulkarni, M. R. Jantz, and D. B. Whalley, "Improving both the performance benefits and speed of optimization phase sequence searches", ACM SIGPLAN/SIGBED Conf. on Languages, Compilers, and Tools for Embedded Systems (LCTES'10), pp.95--104, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. J. J. Willcock, A. Lumsdaine and D. J. Quinlan, "Reusable, generic program analyses and transformations", 8th Int. Conf. on Generative Programming and Component Engineering (GPCE'09), pp.5--14, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. R. J. Meeuws, C. Galuzzi and K. L. M. Bertels, "High Level Quantitative Hardware Prediction Modeling using Statistical methods", Int. Conf. on Embedded Computer Systems: Architectures, Models, and Simulations (SAMOS'10), pp.140--149, 2011.Google ScholarGoogle Scholar
  28. O.S. Dragomir, "K-loops: Loop Transformations for Reconfigurable Architectures", PhD Thesis, TU Delft, Faculty of Elektrotechniek, Wiskunde en Informatica, Delft, Netherlands, 2011.Google ScholarGoogle Scholar
  29. J. Cavazos and M. F. P. O'Boyle, "Method-specific dynamic compilation using logistic regression", ACM Int. Conf. on Object-Oriented Programming Systems, Languages, and Applications (OOPSLA'06), pp.229--240, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. R. Sanchez, et al., "Using machines to learn method-specific compilation strategies", Int. Symp. on Code Generation and Optimization (CGO'11), pp. 257--266, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. J. Y. Le Boudec and P. Thiran, "Network Calculus: A Theory of Deterministic Queuing Systems for the Internet", Springer-Verlag, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. K. Richter, et al., "Bottom-up performance analysis of HW/SW platforms", Design and Analysis of Distributed Embedded Systems (DIPES'02), pp.173--183, IFIP, vol. 91, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. M. Haneda, P. M. W. Knijnenburg and H. A. G. Wijshoff, "Optimizing general purpose compiler optimization", 2nd Conf. on Computing frontiers (CF'05), pp.180--188, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. F. Agakov, et al., "Using Machine Learning to Focus Iterative Optimization", Int. Symp. on Code Generation and Optimization, (CGO'06), pp. 295--305, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. Z. Pan and R. Eigenmann, "PEAK: a fast and effective performance tuning system via compiler optimization orchestration", ACM Trans. on Programming Languages and Systems, vol. 30, no. 3, pp.1--17, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. G. Fursin, et al., "Milepost GCC: machine learning enabled self- tuning compiler", Int. Journal of Parallel Programming, vol. 39, no. 3, pp.296--327, Springer, 2011.Google ScholarGoogle ScholarCross RefCross Ref

Index Terms

  1. Exploration of compiler optimization sequences using clustering-based selection

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in

    Full Access

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader
    About Cookies On This Site

    We use cookies to ensure that we give you the best experience on our website.

    Learn more

    Got it!