Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/12276.13334acmconferencesArticle/Chapter ViewAbstractPublication PagesplanConference Proceedingsconference-collections
Article
Free access

A retargetable instruction reorganizer

Published: 01 July 1986 Publication History
  • Get Citation Alerts
  • Abstract

    Extant peephole optimizers can perform many optimizations that are handled by higher-level optimizers. This paper describes a retargetable instruction reorganizer that performs targeting and evaluation order determination by applying a well known algorithm for optimal code generation for expressions to object code. By applying the algorithm to object code after code generation and optimization, a phase ordering problem often encountered by higher-level optimizers is avoided. It minimizes the number of registers and temporaries required to compile expressions by rearranging machine instructions. For some machines, this can result in smaller and faster programs. By generalizing its operation, the reorganizer can also be used to reorder instructions to avoid delays in pipelined machines. For one pipelined machine, it has provided a 5 to 10 percent improvement in the execution speed of benchmark programs.

    References

    [1]
    A. V. Aho and S. C. Johnson, Optimal Code Generation for Expression Trees, Journal of the ACM 23, 3 (July 1976), 488-501.
    [2]
    A. V. Aho, S. C. Johnson and J. D. Ullman, Code Generation for Expressions with Common Subexpressions, Journal of the ACM 24, 1 (January 1977), 146-160.
    [3]
    A. V. Aho, R. Sethi and J. D. U11man, Compilers Principles, Techniques, and Toots, Addison-Wesley, Reading, MA, 1986.
    [4]
    M. Auslander and M. Hopkins, An Overview of the PL.8 Compiler, Proceedings of the ACM SIGPLAN Notices '82 Symposium on Compiler Construction, Boston, MA, June 1982, 22-31.
    [5]
    J. Bruno and R. Sethi, Code Generation for a One-Register Machine, Journal of the ACM 23, 3 (July 1976), 502-510.
    [6]
    G. J. Chaitin, M. A. Auslander, A. K. Chandra, J. Cocke, M. E. Hopkins and P. W. Markstein, Register Allocation via Coloring, Computer Languages 6, 1 (1981), 47-57.
    [7]
    J. W. Davidson and C. W. Fraser, The Design and Application of a Retargetable Peephole Optimizer, ACM Transactions on Programming Languages and Systems 2, 2 (April 1980), 191-202.
    [8]
    J. W. Davidson and C. W. Fraser, Code Selection through Object Code Optimization, Transactions on Programming Languages and Systems 6, 4 (October 1984), 7-32.
    [9]
    J. W. Davidson and C. W. Fraser, Register Allocation and Exhaustive Peephole Optimization, Software - Practice and Experience14, 9 (September 1984), 857-866.
    [10]
    VAX Architecture Handbook, Digital Equipment Corporation, Maynard, MA, 1981.
    [11]
    C. W. Fraser, A Generalization of Two Code Ordering Optimizations, Tech. Rep. 82-11, University of Arizona, Tucson, AZ, October 1982.
    [12]
    R. Giegerich, A Formal Framework for the Derivation of Machine-Specific Optimizers, Transactions on Programming Languages and Systems 5, 3 (July 1983), 478-498.
    [13]
    D. R. Hanson, The Y Programming Language, SIGPLAN Notices 16, 2 (February 1981), 59-68.
    [14]
    J. Hennessy and T. Gross, Postpass Code Optimization of Pipeline Constraints, AC M Transactions on Programming Languages and Systems 5, 3 (July 1983), 422-448.
    [15]
    S. C. Johnson, A Portable Compiler: Theory and Practice, Proceedings of the Fifth Annual Symposium on Principles of Programming Languages, Tucson, AZ, january 1978, 9%104.
    [16]
    B. W. Kernighan and D. M. Ritchie, The C Programming ixmguage, Prentice- Hall, Englewood Cliffs, NJ, 1978.
    [17]
    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, CMU-C~- 79-105, Carnegie-Mellon University, Pittsburg, PA, February 1979.
    [18]
    A. Lunde, More Data of the O/W Ratios: A Note on a Paper by Flynn, Computer Architecture News 4, 1 (March 1975), 9-13.
    [19]
    M. K. McKusick, Register Allocation and Data Conversion in Machine Independent CxMe Generators, PhD Dissertation, University of California, Berkeley, CA, November 1984.
    [20]
    G. Radin, The 801 Minicomputer, Proceedings of the Symposium on Architectural Support for Programming l_xmguages and Operating Systems, Palo Alto, CA, March 1982, 39-47.
    [21]
    J. W. Rymarczyk, Coding Guidelines for Pipelined Processors, Proceedings of the Symposium on Architectural Support for Programming Languagesand Operating Systems, Palo Alto, CA, March 1982, 12-19.
    [22]
    B. R. Schatz, Algorithms for Optimizing Transformations in a General Purpose Compiler: Propagation and Renaming, RC 6232, IBM Thomas J. Watson Research Center, Yorktown Heights, NY, October 1976.
    [23]
    R. Sethi and J. D. Ullman, The Generation of Optimal Code for Arithmetic Expressions, Journal of the ACM 17, 6 (October 1970), 715-728.
    [24]
    P. F. Stockhauseh, Adapting Optimal Code Genera tion for Arithmetic Expressions to the Instruction Sets Available on Present-Day Computers, Communications of the ACM 16, 6 (June 1973), 353-354.
    [25]
    W. M. Waite, Optimization, in Compiler Construction: An Advanced Course, F. L. Bauer and J. Eickel (ed.), Springer- Verlag, New York, NY, 1976, 549-602.
    [26]
    W. Wulf, R. K. Johnsson, C. B. Weinstock, S. O. Hobbs and C. M. Geschke, The Design of an Optimizing Compiler, American Elsevier, New York, NY, 1975.

    Cited By

    View all
    • (2014)Code scheduling and register allocation in large basic blocksACM International Conference on Supercomputing 25th Anniversary Volume10.1145/2591635.2667158(88-98)Online publication date: 10-Jun-2014
    • (2005)Adaptive compression of syntax trees and iterative dynamic code optimization: Two basic technologies for mobile object systemsMobile Object Systems Towards the Programmable Internet10.1007/3-540-62852-5_19(263-276)Online publication date: 7-Jun-2005
    • (2005)From processor timing specifications to static instruction schedulingStatic Analysis10.1007/3-540-58485-4_36(116-130)Online publication date: 8-Jun-2005
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    SIGPLAN '86: Proceedings of the 1986 SIGPLAN symposium on Compiler construction
    July 1986
    275 pages
    ISBN:0897911970
    DOI:10.1145/12276

    Sponsors

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 01 July 1986

    Permissions

    Request permissions for this article.

    Check for updates

    Qualifiers

    • Article

    Conference

    SCC86
    Sponsor:
    SCC86: SIGPLAN Symposium on Compiler Construction
    June 25 - 27, 1986
    California, Palo Alto, USA

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)62
    • Downloads (Last 6 weeks)11
    Reflects downloads up to 27 Jul 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2014)Code scheduling and register allocation in large basic blocksACM International Conference on Supercomputing 25th Anniversary Volume10.1145/2591635.2667158(88-98)Online publication date: 10-Jun-2014
    • (2005)Adaptive compression of syntax trees and iterative dynamic code optimization: Two basic technologies for mobile object systemsMobile Object Systems Towards the Programmable Internet10.1007/3-540-62852-5_19(263-276)Online publication date: 7-Jun-2005
    • (2005)From processor timing specifications to static instruction schedulingStatic Analysis10.1007/3-540-58485-4_36(116-130)Online publication date: 8-Jun-2005
    • (2005)The advantages of machine-dependent global optimizationProgramming Languages and System Architectures10.1007/3-540-57840-4_27(105-124)Online publication date: 31-May-2005
    • (2005)Scheduling instructions by direct placementCompiler Construction10.1007/3-540-55984-1_21(229-235)Online publication date: 1-Jun-2005
    • (1994)A retargetable technique for predicting execution time of code segmentsReal-Time Systems10.1007/BF010888037:2(159-182)Online publication date: 1-Sep-1994
    • (1993)Isolation and analysis of optimization errorsACM SIGPLAN Notices10.1145/173262.15509328:6(26-35)Online publication date: 1-Jun-1993
    • (1993)Isolation and analysis of optimization errorsProceedings of the ACM SIGPLAN 1993 conference on Programming language design and implementation10.1145/155090.155093(26-35)Online publication date: 1-Aug-1993
    • (1992)A retargetable technique for predicting execution time[1992] Proceedings Real-Time Systems Symposium10.1109/REAL.1992.242675(68-77)Online publication date: 1992
    • (1990)Ease: an environment for architecture study and experimentationACM SIGMETRICS Performance Evaluation Review10.1145/98460.9877518:1(259-260)Online publication date: 1-Apr-1990
    • Show More Cited By

    View Options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Get Access

    Login options

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media