Module Identifier CS24210  
Module Title SYNTAX ANALYSIS AND TOPICS IN PROGRAMMING  
Academic Year 2003/2004  
Co-ordinator Dr Mark B Ratcliffe  
Semester Semester 2  
Other staff Dr Edel M Sherratt  
Co-Requisite CS21120  
Course delivery Lecture   22 lectures  
  Other   Workshop. (Up to) 4 workshop sessions  
  Practical   (Up to) 4 x 2 hr sessions  
Assessment
Assessment TypeAssessment Length/DetailsProportion
Semester Exam2 Hours Written examination100%
Supplementary Exam Will take the same form, under the terms of the Department's policy.   
Further details http://www.aber.ac.uk/compsci/ModuleInfo/CS24210  

Learning outcomes

On successful completion of this module students should be able to:
On successful completion of this course students should be able to:


Brief description

This module aims to familiarise students with the concepts required for specifying and implementing programming languages, and to study their practical applications in a variety of contexts.

Aims

This module aims to familiarise students with the concepts required for specifying and implementing programming languages.

Content

1. Overview of Language Processing Software - 1 Lecture
Editors, compilers, static analysers, interpreters, text formatting, scripting languages.

2. The structure of a typical compiler - 1 Lecture
Lexical, syntactic and semantic analysis; Optimisation and code generation; Implementation; Symbol tables

3. Lexical Analysis - 4 Lectures, 2 Practicals
Lexemes and tokens; Regular Expressions; Finite Automata; Practical use of a scanner generator

4. Syntactic Analysis - 3 Lectures, 2 Practicals
Context free grammars; Parse trees and abstract syntax trees; Parsing strategies (recursive descent, LL, LR); Practical use of a parser generator

5. Intermediate Languages - 2 Lectures
Abstract syntax trees; Reverse polish notation; 3-address code; Attribute grammars and structural attributes

6. Semantic Analysis - 2 Lectures
Different kinds of semantic analysis; Attribute grammars and semantic attributes

7. Code generation - 3 Lectures
Aims of code generation; Memory management, instruction selection and register allocation; Flow graphs; A simple code generator

8. Optimisation and Optimising Compilers - 2 Lectures
Optimisation of source, intermediate and target code; Safety and profitability of optimisation; Flow graphs and optimisation of intermediate code

9. Applications of Compilation Techniques - 4 Lectures
Markup languages; scripting languages;

Reading Lists

Books
** Recommended Text
A.V. Aho, R. Sethi, and J.D. Ullman (1986) Compilers: Principles, Techniques and Tools Addison-Wesley
** Should Be Purchased
J. Bennett (1996) Introduction to Compiling Techniques: a first course using ANSI C, lex and Yacc McGraw-Hill

Notes

This module is at CQFW Level 5