Translating Arithmetic Expressions

Richard Bornat · 1979

Figure 5.1 shows an example arithmetic expression which might appear anywhere in a typical program — say on the right-hand side of an assignment statement — together with the parse tree which describes its structure. It also shows the object code which is the best translation of this expression — ‘best’, that is, if the expression is considered in isolation. The example shows the point from which a compiler-writers’ discussion will start — what translation algorithm will generate this ‘best’ code in practice?

Read the paper · More papers on PaperTik