skip to main content
research-article

Improving both the performance benefits and speed of optimization phase sequence searches

Published: 13 April 2010 Publication History

Abstract

The issues of compiler optimization phase ordering and selection present important challenges to compiler developers in several domains, and in particular to the speed, code size, power, and cost-constrained domain of embedded systems. Different sequences of optimization phases have been observed to provide the best performance for different applications. Compiler writers and embedded systems developers have recently addressed this problem by conducting iterative empirical searches using machine-learning based heuristic algorithms in an attempt to find the phase sequences that are most effective for each application. Such searches are generally performed at the program level, although a few studies have been performed at the function level. The finer granularity of function-level searches has the potential to provide greater overall performance benefits, but only at the cost of slower searches caused by a greater number of performance evaluations that often require expensive program simulations. In this paper, we evaluate the performance benefits and search time increases of function-level approaches as compared to their program-level counterparts. We, then, present a novel search algorithm that conducts distinct function-level searches simultaneously, but requires only a single program simulation for evaluating the performance of potentially unique sequences for each function. Thus, our new hybrid search strategy provides the enhanced performance benefits of function-level searches with a search-time cost that is comparable to or less than program-level searches.

References

[1]
F. Agakov, E. Bonilla, J. Cavazos, B. Franke, G. Fursin, M. F. P. O'Boyle, J. Thomson, M. Toussaint, and C. K. I. Williams, Using machine learning to focus iterative optimization, CGO '06: Proceedings of the International Symposium on Code Generation and Optimization, pages 295--305, Washington, DC, USA, 2006.
[2]
L. Almagor, K. D. Cooper, A. Grosul, T. J. Harvey, S. W. Reeves, D. Subramanian, L. Torczon, and T. Waterman, Finding effective compilation sequences, LCTES '04: Proceedings of the 2004 ACM SIGPLAN/SIGBED Conference on Languages, Compilers, and Tools for Embedded Systems, pages 231--239, 2004.
[3]
M. E. Benitez and J. W. Davidson, A portable global optimizer and linker, Proceedings of the SIGPLAN'88 Conference on Programming Language Design and Implementation, pages 329--338, ACM Press, 1988. ISBN 0-89791-269-1.
[4]
F. Bodin, T. Kisuki, P. Knijnenburg, M. O'Boyle, and E. Rohou, Iterative compilation in a non-linear optimisation space, Proceedings of the Workshop on Profile and Feedback Directed Compilation.Organized in conjuction with PACT'98, 1998.
[5]
G. E. P. Box, W. G. Hunter, and J. S. Hunter, Statistics for Experimenters: An Introduction to Design, Data Analysis, and Model Building, John Wiley & Sons, 1 edition, June 1978. ISBN:0471093157.
[6]
D. Burger and T. Austin, The SimpleScalar tool set, version 2.0, Proceedings of the SIGARCH Compututer Architecture News, v.25 n.3, pages 13--25, 1997, ISSN 0163-5964.
[7]
J. Cavazos and M. F. P. O'Boyle, Method-specific dynamic compilation using logistic regression, OOPSLA '06: Proceedings of the 21st annual ACM SIGPLAN conference on Object-oriented programming systems, languages, and applications, pages 229--240, 2006. ISBN 1-59593-348-4.
[8]
K. D. Cooper, P. J. Schielke, and D. Subramanian, Optimizing for reduced code space using genetic algorithms, Proceedings of the Workshop on Languages, Compilers, and Tools for Embedded Systems, pages 1--9, May 1999, citeseer.ist.psu.edu/cooper99optimizing.html.
[9]
K. D. Cooper, A. Grosul, T. J. Harvey, S. Reeves, D. Subramanian, L. Torczon, and T. Waterman, Acme: adaptive compilation made efficient, LCTES '05: Proceedings of the 2005 ACM SIGPLAN/SIGBED conference on Languages, compilers, and tools for embedded systems, pages 69--77, 2005. ISBN 1-59593-018-3.
[10]
G. Fursin, A. Cohen, M. O'Boyle, and O. Temam, Quick and practical run-time evaluation of multiple program optimizations, pages 34--53, 2007.
[11]
G. Fursin, C. Miranda, O. Temam, M. Namolaru, E. Yom-Tov, A. Zaks, B. Mendelson, E. Bonilla, J. Thomson, H. Leather, C. Williams, and M. O. Boyle, Milepost gcc: machine learning based research compiler, GCC Summit, 2008, http://www.milepost.eu/.
[12]
J. R. Goodman and W.-C. Hsu, Code scheduling and register allocation in large basic blocks, ICS '88: Proceedings of the 2nd international conference on Supercomputing}, pages 442--452, 1988. ISBN 0-89791-272-1.
[13]
M. R. Guthaus, J. S. Ringenberg, D. Ernst, T. M. Austin, T. Mudge, and R. B. Brown, MiBench: A free, commercially representative embedded benchmark suite, IEEE 4th Annual Workshop on Workload Characterization, December 2001.
[14]
M. Haneda, P. M. W. Knijnenburg, and H. A. G. Wijshoff, Generating new general compiler optimization settings, ICS '05: Proceedings of the 19th Annual International Conference on Supercomputing, pages 161--168, 2005. ISBN 1-59593-167-8.
[15]
M. Haneda, P. M. W. Knijnenburg, and H. A. G. Wijshoff, Automatic selection of compiler options using non-parametric inferential statistics, PACT '05: Proceedings of the 14th International Conference on Parallel Architectures and Compilation Techniques, pages 123--132, Washington, DC, USA, 2005, IEEE Computer Society. ISBN 0-7695-2429-X.
[16]
K. Hoste and L. Eeckhout, Cole: Compiler optimization level exploration, CGO '08: Proceedings of the sixth annual IEEE/ACM international symposium on Code generation and optimization, pages 165--174, Boston, MA, USA, 2008.
[17]
T. Kisuki, P. Knijnenburg, M. O'Boyle, F. Bodin, and H. Wijshoff, A feasibility study in iterative compilation, Proceedings of ISHPC'99, volume 1615 of Lecture Notes in Computer Science, pages 121--132, 1999.
[18]
T. Kisuki, P. Knijnenburg, and M. O'Boyle, Combined selection of tile sizes and unroll factors using iterative compilation, Proceeding of the Internation Conference on Parallel Architectures and Compilation Techniques, pages 237--246, 2000.
[19]
P. Kulkarni, W. Zhao, H. Moon, K. Cho, D. Whalley, J. Davidson, M. Bailey, Y. Paek, and K. Gallivan, Finding effective optimization phase sequences, Proceedings of the 2003 ACM SIGPLAN Conference on Languages, Compilers, and Tools for Embedded Systems, pages 12--23. ACM Press, 2003. ISBN 1-58113-647-1.
[20]
P. Kulkarni, S. Hines, J. Hiser, D. Whalley, J. Davidson, and D. Jones, Fast searches for effective optimization phase sequences, Proceedings of the ACM SIGPLAN '04 Conference on Programming Language Design and Implementation, pages 171--182, Washington DC, USA, June 2004.
[21]
P. Kulkarni, D. Whalley, G. Tyson, and J. Davidson, Exhaustive optimization phase order space exploration, Proceedings of the Fourth Annual IEEE/ACM International Symposium on Code Generation and Optimization, pages 306--308, March 26--29, 2006.
[22]
P. Kulkarni, D. Whalley, G. Tyson, and J. Davidson, In search of near-optimal optimization phase orderings, LCTES '06: Proceedings of the 2006 ACM SIGPLAN/SIGBED conference on Language, compilers and tool support for embedded systems, pages 83--92, New York, NY, USA, 2006, ACM Press. ISBN 1-59593-362-X.
[23]
P. A. Kulkarni, S. R. Hines, D. B. Whalley, J. D. Hiser, J. W. Davidson, and D. L. Jones, Fast and efficient searches for effective optimization-phase sequences, Proceedings of the ACM Transactions on Architecture and Code Optimization, 2(2):165--198, 2005, ISSN 1544-3566.
[24]
P. A. Kulkarni, D. B. Whalley, and G. S. Tyson, Evaluating heuristic optimization phase order search algorithms, CGO '07: Proceedings of the International Symposium on Code Generation and Optimization, pages 157--169, Washington, DC, USA, 2007. IEEE Computer Society. ISBN 0-7695-2764-7.
[25]
B. W. Leverett, R. G. G. Cattell, S. O. Hobbs, J. M. Newcomer, A. H. Reiner, B. R. Schatz, and W. A. Wulf, An overview of the production-quality compiler-compiler project, Computer, 13(8):38--49, 1980. ISSN 0018-9162.
[26]
M. Mitchell, An Introduction to Genetic Algorithms, Cambridge, Mass. MIT Press, 1996.
[27]
Z. Pan and R. Eigenmann, Fast and effective orchestration of compiler optimizations for automatic performance tuning, CGO '06: Proceedings of the International Symposium on Code Generation and Optimization, pages 319--332, Washington, DC, USA, 2006. IEEE Computer Society. ISBN 0-7695-2499-0.
[28]
S. Triantafyllis, M. Vachharajani, N. Vachharajani\, and D. I. August, Compiler optimization--space exploration, Proceedings of the International Symposium on Code Generation and Optimization, pages 204--215, IEEE Computer Society, 2003. ISBN 0-7695-1913-X.
[29]
S. R. Vegdahl, Phase coupling and constant generation in an optimizing microcode compiler, Proceedings of the 15th Annual Workshop on Microprogramming, pages 125--133, IEEE Press, 1982.
[30]
D. Whitfield and M. L. Soffa, An approach to ordering optimizing transformations. Proceedings of the second ACM SIGPLAN symposium on Principles & Practice of Parallel Programming, pages 137--146. ACM Press, 1990. ISBN 0-89791-350-7.
[31]
M. Zhao, B. Childers, and M. L. Soffa, Predicting the impact of optimizations for embedded systems, LCTES '03: Proceedings of the 2003 ACM SIGPLAN Conference on Language, compiler, and tool for embedded systems, pages 1--11, New York, NY, USA, 2003. ACM Press. ISBN 1-58113-647-1.
[32]
M. Zhao, B. R. Childers, and M. L. Soffa, A model-based framework: An approach for profit-driven optimization, Proceedings of the International Symposium on Code Generation and Optimization, pages 317--327, Washington, DC, USA, 2005. ISBN 0-7695-2298-X.

Cited By

View all
  • (2017)Piecewise holistic autotuning of parallel programs with CEREConcurrency and Computation: Practice and Experience10.1002/cpe.419029:15Online publication date: 20-Jun-2017
  • (2016)Clustering-Based Selection for the Exploration of Compiler Optimization SequencesACM Transactions on Architecture and Code Optimization10.1145/288361413:1(1-28)Online publication date: 28-Mar-2016
  • (2016)Piecewise Holistic Autotuning of Compiler and Runtime ParametersProceedings of the 22nd International Conference on Euro-Par 2016: Parallel Processing - Volume 983310.1007/978-3-319-43659-3_18(238-250)Online publication date: 24-Aug-2016
  • Show More Cited By

Index Terms

  1. Improving both the performance benefits and speed of optimization phase sequence searches

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    LCTES '10: Proceedings of the ACM SIGPLAN/SIGBED 2010 conference on Languages, compilers, and tools for embedded systems
    April 2010
    184 pages
    ISBN:9781605589534
    DOI:10.1145/1755888
    • cover image ACM SIGPLAN Notices
      ACM SIGPLAN Notices  Volume 45, Issue 4
      LCTES '10
      April 2010
      170 pages
      ISSN:0362-1340
      EISSN:1558-1160
      DOI:10.1145/1755951
      Issue’s Table of Contents
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Sponsors

    In-Cooperation

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 13 April 2010

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. genetic algorithms
    2. phase ordering

    Qualifiers

    • Research-article

    Conference

    LCTES '10

    Acceptance Rates

    Overall Acceptance Rate 116 of 438 submissions, 26%

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)4
    • Downloads (Last 6 weeks)1
    Reflects downloads up to 19 Oct 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2017)Piecewise holistic autotuning of parallel programs with CEREConcurrency and Computation: Practice and Experience10.1002/cpe.419029:15Online publication date: 20-Jun-2017
    • (2016)Clustering-Based Selection for the Exploration of Compiler Optimization SequencesACM Transactions on Architecture and Code Optimization10.1145/288361413:1(1-28)Online publication date: 28-Mar-2016
    • (2016)Piecewise Holistic Autotuning of Compiler and Runtime ParametersProceedings of the 22nd International Conference on Euro-Par 2016: Parallel Processing - Volume 983310.1007/978-3-319-43659-3_18(238-250)Online publication date: 24-Aug-2016
    • (2015)Use of Previously Acquired Positioning of Optimizations for Phase Ordering ExplorationProceedings of the 18th International Workshop on Software and Compilers for Embedded Systems10.1145/2764967.2764978(58-67)Online publication date: 1-Jun-2015
    • (2014)Exploration of compiler optimization sequences using clustering-based selectionACM SIGPLAN Notices10.1145/2666357.259782149:5(63-72)Online publication date: 12-Jun-2014
    • (2014)Exploration of compiler optimization sequences using clustering-based selectionProceedings of the 2014 SIGPLAN/SIGBED conference on Languages, compilers and tools for embedded systems10.1145/2597809.2597821(63-72)Online publication date: 12-Jun-2014
    • (2014)A clustering-based approach for exploring sequences of compiler optimizations2014 IEEE Congress on Evolutionary Computation (CEC)10.1109/CEC.2014.6900634(2436-2443)Online publication date: Jul-2014
    • (2014)Analyzing and addressing false interactions during compiler optimization phase orderingSoftware—Practice & Experience10.1002/spe.217644:6(643-679)Online publication date: 1-Jun-2014
    • (2013)Performance potential of optimization phase selection during dynamic JIT compilationACM SIGPLAN Notices10.1145/2517326.245153948:7(131-142)Online publication date: 16-Mar-2013
    • (2013)Performance potential of optimization phase selection during dynamic JIT compilationProceedings of the 9th ACM SIGPLAN/SIGOPS international conference on Virtual execution environments10.1145/2451512.2451539(131-142)Online publication date: 16-Mar-2013
    • Show More Cited By

    View Options

    Get Access

    Login options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media