The Middle-End of ["GCC"] performs ["SSA"] based optimizations on ["GIMPLE"], then converts the ["GIMPLE"] to ["RTL"] and does more optimizations. Finally it hands it off the optimized RTL to the ["BackEnd"].

Work has started on performing ["Interprocedural optimizations"] in GCC. See also the ["ipa-branch"] and the -fwhole-program compilation flag (useful when passing a whole program source as several compilation units passed together to the compiler).

middle end passes

The following passes are done on the GIMPLE SSA representation. please check this list

  1. Many passes are working on trees before the SSA, in particular for the call flow graph (the pass_build_cfg is building it in file gcc/tree-cfg.c) and tree inlining (pass_ipa_inline in file gcc/ipa-inline.c)

  2. the pass_build_ssa (in file gcc/tree-into-ssa.c) is building the SSA representation

  3. the pass_lower_vector and pass_lower_vector_ssa (file gcc/tree-vect-generic.c) are expanding vector to scalar operations (???)


The ["tree folder"] is also considered part of the middle-end, but the ["FrontEnd"]s use it for constant folding also.