
160 Compilers – Principles and Practice
The Symbol Table is accessed at every stage of the compilation process:
Scanning: Insertion of new identifiers.
Parsing: Access to ensure that an operand exists.
Semantic analysis:
c
Determination of types of identifiers from declarations,
c
Type checking to ensure that operands are used in type-valid contexts,
c
Checking scope, visibility violations.
Intermediate Representation generation: Memory allocation and relative address calculation for
jumps etc.
Optimization: All memory accesses are through the Symbol Table.
Target code generation: Translation of relative addresses to absolute addresses in terms ...