University Of Pretoria Computer Science Department

COS341 - Compiler Construction

Announcements

Module Content

Assignment Specifications - Assignment Specifications
Project 1: Tokens and Syntax
Task 1a
Lexical Analysis of SPL
Task specification in PDF (printable on paper)
Lexical Analysis of SPL
Task specification in PPS (for viewing on screen)
Task 1b
Syntax Analysis of SPL
Task specification in PDF (printable on paper)
Syntax Analysis of SPL
Task specification in PPS (for viewing on screen)
Project 2: Static Semantics
Task 2a
Type Analysis of SPL
Task specification in PDF (printable on paper)
Type Analysis of SPL
Task specification in PPS (for viewing on screen)
Task 2b
Scope Analysis of SPL
Task specification in PDF (printable on paper)
Scope Analysis of SPL
Task specification in PPS (for viewing on screen)
Task 2c
Value Analysis of SPL
Task specification in PDF (printable on paper)
Value Analysis of SPL
Task specification in PPS (for viewing on screen)
Project 3: Code Generation
Task 3a
Intermediate Code Preparation
Task specification in PDF (printable on paper)
Intermediate Code Preparation
Task specification in PPS (for viewing on screen)
Task 3b
Intermediate Code Generation
Task specification in PDF (printable on paper)
Intermediate Code Generation
Task specification in PPS (for viewing on screen)
SPL TEST CASE: Bank Account Program
In this file you can find a bank account program in SPL. Your code generator should be able to generate proper BASIC code for this bank account program! Then you will also have a good chance of passing the Project #3 Demo on the 16th of May. The SPL "HALT" command should best be translated into a GOTO jump which jumps to the very end of the generated BASIC program.
Task 3c
Intermediate Code Optimisation
Task specification in PDF (printable on paper)
Intermediate Code Optimisation
Task specification in PPS (for viewing on screen)
LESSONS on Code Optimisation
Must be studied in your own time (together with your project partner)

Module forums

The new CS forums are available here.

Module Links

Topic: undecidability problems with context-free grammars. All COS341 students MUST read this technical report.
Many computing or computer science degree programmes include at least one module where students are required to design abstract computing machines to recognise words in given languages. These kinds of design tasks are difficult to teach and to learn. This research study focused on the easiest of these design tasks and was an initial attempt to understand the types of mistakes that students make when designing Finite Automata words in given regular languages.

Login

Username:
Password:
Remember Me

Module Description

THIS WEB PAGE IS THE STUDY GUIDE for COS341: COMPILER CONSTRUCTION. Please carefully take note of all further announcements which will appear on this web page! In COS341 we follow ...

Show Long Description

Lecturer Information

Course Coordinator

Prof Stefan Gruner

Lecturers

Assistant Lecturers

Tutors

There are no tutors assigned.

Teaching Assistants

There are no teaching assistants assigned.

Class Representatives

English Representatives

Mr Dewald de Jager

Miss Nikki Constancon

H.o.D Office times

During the times below, any student can come and discuss any issue with the head of the department without making an appointment. Note that these dates and times may change, and any such changes will be updated on each module home page.

The dates and times are as follows:
  • 05 May 12:30-13:30
  • 08 May 08:00-09:00
  • 12 May 12:30-13:30

Active Assignments

No currently active Assignments

Active Fitch Fork Assignments

No currently active Fitch Fork Assignments

Active Bookings

    No bookings available

Lab Bookings

    No lab bookings available

Active Team Allocations

    No team allocations available

Active Bids

Individual Bids

    No individual bids

Team Bids

    No team bids

Team Pages

Team Pages

    No Team Pages

Team Pages Open to Module Members

    No Public Team Pages

Team Pages Open to Everyone

    No Public Team Pages

Active Polls

All content copyright © Department of Computer Science, School of IT, University of Pretoria, South Africa