Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
article

Automatic generation of compiler backends

Published: 01 February 2013 Publication History

Abstract

Application-specific instruction set processors have proven successful in meeting the various design constraints of modern embedded systems and often provide the only viable trade-off between computing power and opposing metrics such as power consumption. A promising approach to facilitate the exploration of processor design alternatives are processor description languages, which capture the instruction set and hardware organization of a processor. With the use of those processor models, various design tasks, for example, the adaption of software development tools, the generation of hardware models, and various verification tasks, can be automatized. These languages thus allow effective shortening of development turnaround times. In this work, the novel xADL language is presented, which, in contrast to most contemporary processor description languages, focuses on a structural modeling of the processor's hardware organization. However, a behavioral model of the instruction set is automatically derived using instruction set extraction. This provides a tight coupling between the structural hardware view and the instruction set view of the processor and reduces the complexity of processor models in comparison with existing languages. The feasibility of our approach is demonstrated by a compiler backend generator based on tree pattern matching. An important property of our generator is its ability to automatically verify whether the resulting compiler is complete, that is, it can process all possible input programs. The generated compilers are competitive to handcrafted production compilers, showing speedups of up to 20% for certain benchmarks. On average, moderate slowdowns between 3% and 15% have been observed for several processor models while considerable reductions in code size have been measured. Copyright © 2012 John Wiley & Sons, Ltd.

References

[1]
Brandner F, Ebner D, Krall A .Compiler generation from structural architecture descriptions. CASES '07: Proceedings of the International Conference on Compilers, Architecture, and Synthesis for Embedded Systems,2007; pp.13-22.
[2]
Brandner F .Completeness of automatically generated instruction selectors. InASAP '10: International Conference on Application-Specific Systems, Architectures and Processors .IEEE,2010; pp.175-182.
[3]
Comon H, Dauchet M, Gilleron R, Löding C, Jacquemard F, Lugiez D, Tison S, Tommasi M. Tree automata techniques and applications,2007 .http://www.grappa.univ-lille3.fr/tata.
[4]
Aho AV, Ganapathi M, Tjiang SWK .Code generation using tree matching and dynamic programming .ACM Transactions on Programming Languages and Systems TOPLAS 1989 ;Volume 11 Issue 4: pp.491-516.
[5]
Aho AV, Johnson SC .Optimal code generation for expression trees .Journal of the ACM JACM 1976 ;Volume 23 Issue 3: pp.488-501.
[6]
Hoffmann CM, O'Donnell MJ .Pattern matching in trees .Journal of the ACM JACM 1982 ;Volume 29 Issue 1: pp.68-95.
[7]
Emmelmann H, Schröer FW, Landwehr R .BEG: a generator for efficient back ends. InPLDI '89: Proceedings of the Conference on Programming Language Design and Implementation .ACM,1989; pp.227-237.
[8]
Fraser CW, Hanson DR, Proebsting TA .Engineering a simple, efficient code-generator generator .ACM Letters on Programming Languages and Systems LOPLAS 1992 ;Volume 1 Issue 3: pp.213-226.
[9]
Glesner S, Geiβ R, Boesler B .Verified code generation for embedded systems .Electronic Notes in Theoretical Computer Science 2002 ;Volume 65 Issue 2: pp.19-36. COCV'02, Compiler Optimization Meets Compiler Verification.
[10]
Cytron R, Ferrante J, Rosen BK, Wegman MN, Zadeck FK .Efficiently computing static single assignment form and the control dependence graph .ACM Transactions on Programming Languages and Systems TOPLAS 1991 ;Volume 13 Issue 4: pp.451-490.
[11]
Eckstein E, König O, Scholz B .Code instruction selection based on SSA-graphs .LNCS - Software and Compilers for Embedded Systems 2003 ;Volume 2826/2003: pp.49-65.
[12]
Necula GC, Lee P .The design and implementation of a certifying compiler. InPLDI '98: Proceedings of the Conference on Programming Language Design and Implementation .ACM :New York, NY, USA,1998; pp.333-344.
[13]
Pnueli A, Siegel M, Singerman E .Translation validation. In TACAS '98: Proceedings of the International Conference on Tools and Algorithms for Construction and Analysis of Systems .Springer :London, UK,1998; pp.151-166.
[14]
Zimmermann W .On the correctness of transformations in compiler back-ends. InLeveraging Applications of Formal Methods, Vol.Volume 4313,<bookSeriesTitle>LNCS</bookSeriesTitle>,Springer :Berlin / Heidelberg, Gemany,2006; pp.74-95.
[15]
Leroy X .Formal certification of a compiler back-end or: programming a compiler with a proof assistant. In POPL '06: Conference Record of the Symposium on Principles of Programming Languages,ACM :New York, NY, USA,2006; pp.42-54.
[16]
Emmelmann H .Testing completeness of code selector specifications. In CC '92: Proceedings of the International Conference on Compiler Construction .Springer :London, UK,1992; pp.163-175.
[17]
Giegerich R, Schmal K .Code selection techniques: pattern matching, tree parsing, and inversion of derivors. InESOP '88: Proceedings of the European Symposium on Programming .Springer :London, UK,1988; pp.247-268.
[18]
Buchwald S, Zwinkau A .Befehlsauswahl auf expliziten abhängigkeitsgraphen. Master's Thesis, Institut für Programmstrukturen und Datenorganisation, Universität Karlsruhe, 2008.
[19]
Fauth A, Praet JV, Freericks M .Describing instruction set processors using nML. EDTC '95: Proceedings of the European Conference on Design and Test,1995; pp.503-507.
[20]
VanPraet J, Lanneer D, Geurts W, Goossens G .Processor modeling and code selection for retargetable compilation .ACM Transactions on Design Automation of Electronic Systems TODAES 2001 ;Volume 6 Issue 3: pp.277-307.
[21]
Pees S, Hoffmann A, ¿ivojnović V, Meyr H .LISA - machine description language for cycle-accurate models of programmable DSP architectures. DAC '99: Proceedings of the Conference on Design Automation,1999; pp.933-938.
[22]
Ceng J, Hohenauer M, Leupers R, Ascheid G, Meyr H, Braun G .C compiler retargeting based on instruction semantics models. DATE '05: Proceedings of the Conference on Design, Automation and Test in Europe,2005; pp.1150-1155.
[23]
Halambi A, Grun P, Ganesh V, Khare A, Dutt N, Nicolau A .EXPRESSION: a language for architecture exploration through compiler/simulator retargetability .DATE '99: Proceedings of the Conference on Design, Automation and Test in Europe,1999; pp.485-490.
[24]
Marwedel P .The MIMOLA design system: tools for the design of digital processors. DAC '84: Proceedings of the Conference on Design Automation,1984; pp.587-593.
[25]
Leupers R, Marwedel P .Retargetable generation of code selectors from HDL processor models. EDTC '97: Proceedings of the European Conference on Design and Test,1997; pp.140-144.
[26]
Leupers R, Marwedel P .Retargetable code generation based on structural processor descriptions. InDesign Automation for Embedded Systems .Kluwer Academic Publishers,Netherlands,1998; pp.1-36.
[27]
Akaboshi H, Yasuura H .Behavior extraction of MPU from HDL description .APCHDL '94: Proceedings of the Asia Pacific Conference on Hardware Description Languages,1994; pp.67-74.
[28]
Mishra P, Dutt N .Processor Description Languages, Vol.Volume 1,Morgan Kaufmann :Burlington, MA, USA,2008.
[29]
Brandner F .Compiler backend generation from structural processor models. PhD Thesis, Institut für Computersprachen, Technische Universität Wien, 2009.
[30]
Patterson DA, Hennessy JL .Computer Organization & Design: The Hardware/Software Interface, 3rd edn,Morgan Kaufmann :Waltham, MA, USA,2007.
[31]
Bondy JA, Murty USR .Graduate Texts in Mathematics - Graph Theory, Vol.Volume 244 .Springer :Heidelberg, Germany,2007.
[32]
Brandner F .Fast and accurate simulation using the LLVM compiler framework .RAPIDO '09: Workshop on Rapid Simulation and Performance Evaluation: Methods and Tools,2009.
[33]
Brandner F .Precise simulation of interrupts using a rollback mechanism .SCOPES '09: Proceedings of the International Workshop on Software and Compilers for Embedded Systems,2009; pp.71-80.
[34]
Lattner C, Adve V .LLVM: a compilation framework for lifelong program analysis & transformation. CGO '04: Proceedings of the International Symposium on Code Generation and Optimization,2004; pp.75-86.
[35]
Ebner D, Brandner F, Scholz B, Krall A, Wiedermann P, Kadlec A .Generalized instruction selection using SSA-graphs. InLCTES '08: Proceedings of the Conference on Languages, Compilers, and Tools for Embedded Systems .ACM :New York, NY, USA,2008; pp.31-40.
[36]
Delvai M, Huber W, Puschner P, Steininger A .Processor support for temporal predictability - the SPEAR design example. InProceedings of the International Conference on Real-Time Systems .IEEE,2003; pp.169-176.
[37]
ON DEMAND Microelectronics.ODM CHILI Programmer's Guide .ON DEMAND Microelectronics,2006. ODM 301000106-V020.
[38]
Azevedo R, Rigo S, Bartholomeu M, Araujo G, Araujo C, Barros E .The ArchC architecture description language and tools .International Journal of Parallel Programming 2005 ;Volume 33 Issue 5: pp.453-484.
[39]
Guthaus MR, Ringenberg JS, Ernst D, Austin TM, Mudge T, Brown RB .MiBench: a free, commercially representative embedded benchmark suite. Proceedings of the Workshop on Workload Characterization,2001.
[40]
Lee C, Potkonjak M, Mangione-Smith WH .MediaBench: a tool for evaluating and synthesizing multimedia and communicatons systems. InMICRO 30: Proceedings of the International Symposium on Microarchitecture .IEEE :Washington, DC, USA,1997; pp.330-335.
[41]
Allen JR, Kennedy K, Porterfield C, Warren J .Conversion of control dependence to data dependence. InProceedings of the Symposium on Principles of Programming Languages,<bookSeriesTitle>POPL '83</bookSeriesTitle>.ACM :New York, NY, USA,1983; pp.177-189.
[42]
Fisher JA, Faraboschi P, Cliff Y .Embedded Computing: A VLIW Approach to Architecture, Compilers and Tools .Morgan Kaufmann Elsevier :Waltham, MA, USA,2005.

Cited By

View all
  • (undefined)Flow-based computing on nanoscale crossbars: Design and implementation of full adders2016 IEEE International Symposium on Circuits and Systems (ISCAS)10.1109/ISCAS.2016.7538936(1870-1873)

Index Terms

  1. Automatic generation of compiler backends
    Index terms have been assigned to the content through auto-classification.

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image Software—Practice & Experience
    Software—Practice & Experience  Volume 43, Issue 2
    February 2013
    129 pages

    Publisher

    John Wiley & Sons, Inc.

    United States

    Publication History

    Published: 01 February 2013

    Author Tags

    1. compiler
    2. completeness
    3. instruction selection
    4. processor description languages

    Qualifiers

    • Article

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)0
    • Downloads (Last 6 weeks)0
    Reflects downloads up to 13 Sep 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (undefined)Flow-based computing on nanoscale crossbars: Design and implementation of full adders2016 IEEE International Symposium on Circuits and Systems (ISCAS)10.1109/ISCAS.2016.7538936(1870-1873)

    View Options

    View options

    Get Access

    Login options

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media