Basic Blocks and Control-Flow Graphs
Optimisation and code generation work on three-address code organised into basic blocks: maximal straight-line sequences that control enters only at the top and leaves only at the bottom.
Compiler Design · topic
Leaders, basic blocks and flow graphs, loops and dominators, the DAG of a block, common-subexpression and dead-code elimination, folding, copy propagation, strength reduction, peephole rules and register counts.
Optimisation and code generation work on three-address code organised into basic blocks: maximal straight-line sequences that control enters only at the top and leaves only at the bottom.
Local optimisation improves one basic block at a time, using only what is known inside the block.
An expression is a common subexpression if it was computed earlier and its operands have not changed since. Reusing the earlier value is common subexpression elimination; across blocks it relies on the available expressions analysis.
One-page visual sheets for this topic, in the sheet library on the store. Previews are free; the full sheets come with the subject pack.