G52CMP Lecture Note Index
Spring 2010
This page will contain links to all electronic material used during the
lectures, in particular electronic slides and any major pieces of code.
The slides are all in PDF, and there are three versions available for
each lecture. The basic version is intended for on-screen viewing only,
whereas the 4-up and 9-up versions are mainly intended for printing,
putting 4 and 9 slides respectively on each page. (The format of any slides
for guest lectures, however, could be different.)
Lecture 1: Administrative Details and
Introduction
26 January 2010
Lecture 2: Haskell Revision
27 January 2010
Lecture S1: Coursework Support Lecture 1
29 January 2010
Lecture 3 & 4: A Complete (Albeit Small)
Compiler
2 & 3 February 2010
-
Slides
-
Slides 4 up
-
Slides 9 up
-
Handout
-
The TXL Compiler Example
-
TXL2C Haskell source code
-
txl2c executable Should run on most
x86-based Linux systems. Tested on RedHat 7.3 and RedHat 9.
Not for Windows/Mac. Sorry.
-
Example 1: TXL source code,
token sequence,
Abstract Syntax Tree,
pretty-printed Abstract Syntax
Tree,
generated C code.
-
Example 2: TXL source code,
token sequence,
Abstract Syntax Tree,
pretty-printed Abstract Syntax
Tree,
generated C code.
-
And finally, for you enjoyment, the x86
assembly code generated by GCC (the GNU C Compiler) for Example 1,
and a hexadecimal dump of of the resulting
machine code.
Lecture 5: Defining Programming Languages I
9 February 2010
Lecture 6: Defining Programming Languages II
10 February 2010
Lecture 7: Syntactic Analysis: Bottom-Up Parsing
16 February 2010
Lecture 8: Syntactic Analysis: Parser Generators
17 February 2010
Lecture 9: Contextual Analysis: Scope I
23 February 2010
Lecture 10: Contextual Analysis: Scope II
24 February 2010
Lecture S2: Coursework Support Lecture 2: Monads
26 February 2010
Lecture 11: Contextual Analysis: Types and Type Systems I
2 March 2010
Lecture 12: Contextual Analysis: Types and Type Systems II
3 March 2010
Lecture 13 & 14:
Contextual Analysis: Implementing A Type Checker
9 & 10 March 2010
Lecture 15 & 16: Code Generation I
16 & 17 March 2010
Lecture 17: Code Generation II
23 March 2010
Lecture 18: Run Time Organisation
24 March 2010
Lecture 19 & 20: Code Optimization
30 & 31 March 2010
Last updated 31 Mar 2010.