Index: htdocs/projects/ast-optimizer.html =================================================================== RCS file: ast-optimizer.html diff -N ast-optimizer.html *** /dev/null Tue May 5 13:32:27 1998 --- ast-optimizer.html Sun Jul 22 07:10:43 2001 *************** *** 0 **** --- 1,124 ---- + + + Abstract Syntax Tree Optimizations + + + +

Abstract Syntax Tree Optimizations

+ +

This page describes ongoing work to improve GCC's tree based + optimizations. There is a branch in CVS called, + ast-optimizer-branch, which is available to experiment with + these optimizers. As these stabilize, they can be submitted for review + onto the mainline development tree. Please contact Nathan Sidwell, + nathan@codesourcery.com, if you want to contribute. + +

Background & Rationale

+ +

GCC, in common with many other compilers, has more than one internal + representation of a program. The main ones are trees and RTL. The + trees, (or formally abstract syntax trees - ASTs) are generated during + parsing, and are close to the source language semantics. The RTL is + generated in the back end, and is close to the generated assembly + code. Ideally, the AST would contain all the semantic information of + the source program. + +

Historically, GCC generated RTL one statement at a time, so + the AST did not stay around very long. This has changed with 'function + at a time' compilation (Inliner), + which both C and C++ frontends now implement. With the AST for complete + functions, and the additional semantic information they contain, the + opportunity for new optimizations presents itself. + +

Goals

+ +

In addition to providing completely new optimization passes, there + are a number of sub goals. + +

+ +

Status

+ + The branch was created from the development mainline on 21 July 2001. + Its version string is 'ast-optimizer-branch'. + + + +

Contributing

+ +

Checkout the ast-optimizer-branch branch + +

+ cvs co -r ast-optimizer-branch gcc
+ 
+ + then configure and build in the normal way. + +

Please post patches in the usual way to the gcc-patches list, marked + [ast-optimizer-branch]. As this is a branch, and not the + mainline, the usual maintainer rules do not apply. This branch is + maintained by Nathan Sidwell, + nathan@codesourcery.com. Approval from the usual maintainer will be + needed when submitting patches from the branch onto the mainline. + + + Index: htdocs/projects/index.html =================================================================== RCS file: /cvs/gcc/wwwdocs/htdocs/projects/index.html,v retrieving revision 1.15 diff -c -3 -p -r1.15 index.html *** index.html 2001/07/19 05:13:12 1.15 --- index.html 2001/07/22 14:11:05 *************** *** 19,24 **** --- 19,25 ----

  • SSA Conditional Constant Propagation Pass
  • Value range propagation pass
  • Automaton based pipeline hazard recognizer +
  • Tree optimization passes
  • Optimizer inadequacies
  • Projects to improve performance on IA-64 *************** automaton based pipeline hazard recogniz *** 136,142 **** instruction scheduling and it provides the base for a future sofware pipelining implementation.

    !

    Optimizer inadequacies

    We also have a page detailing optimizer inadequacies, if you'd prefer to think about it in terms of problems --- 137,146 ---- instruction scheduling and it provides the base for a future sofware pipelining implementation.

    !

    Tree optimization passes

    ! A separate page describes abstract ! syntax tree optimization passes that are being worked on. !

    Optimizer inadequacies

    We also have a page detailing optimizer inadequacies, if you'd prefer to think about it in terms of problems