03-01symtab - Semantic analysis Part 1: Introduction...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
1 CSE 450: Compilers K. Stirewalt Semantic analysis Part 1: Introduction Topics: – symbol tables – large example of a parser that uses symbol tables to aid in analysis Readings: Read Section 2.6 Dragon Book CSE 450: Compilers K. Stirewalt Structure of a Compiler Source Language Target Language Semantic Analyzer Syntax Analyzer Lexical Analyzer Front End Code Optimizer Target Code Generator Back End Int. Code Generator Intermediate Code CSE 450: Compilers K. Stirewalt Today! Source Language Target Language Semantic Analyzer Syntax Analyzer Lexical Analyzer Front End Code Optimizer Target Code Generator Back End Int. Code Generator Intermediate Code CSE 450: Compilers K. Stirewalt Semantic analysis Checks a source program for semantic consistency with the language definition Also gathers type information for use in intermediate-code generation Major components: – Creation of a symbol table – Type checking – Type coercions CSE 450: Compilers K. Stirewalt Semantic consistency example Focus: Analyses pertaining to definitions and
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 3

03-01symtab - Semantic analysis Part 1: Introduction...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online