SWEN430 (2021) - Compiler Engineering
The course looks at a range of issues relating to the design and implementation of modern compilers. In particular, the course will focus on techniques and algorithms for code generation, code optimisation and type checking. During the course projects, students will be working on a fully-fledged compiler for a small imperative language. Students should expect to learn a great deal about how compilers work and, in particular, about the Java Bytecode and x86 instruction sets.
Course learning objectives
Students who pass this course should be able to:
- Understand basic principles of a compiler
- Understand scanning and parsing stages of the compiler
- Understand type checking stages of the compiler, including the basics of type systems
- Understand what dataflow analysis is and how it is used within a compiler
- Understand the code generation stage of the compiler, including knowledge of Java Bytecode
- Have a good background for continued research in these areas
The course is primarily offered in-person, but there will also be a remote option and there will be online alternatives for all the components of the course for students who cannot attend in-person.
Students taking this course remotely must have access to a computer with camera and microphone and a reliable high speed internet connection that will support real-time video plus audio connections and screen sharing. Students must be able to use Zoom; other communication applications may also be used. A mobile phone connection only is not considered sufficient. The computer must be adequate to support the programming required by the course: a reasonably powerful modern windows, macintosh, or unix laptop or desktop computer will be sufficient, but an Android or IOS tablet will not.
If the assessment of the course includes tests, the tests will generally be run in-person on the Kelburn campus. There will be a remote option for students who cannot attend in-person and who have a strong justification (for example, being enrolled from overseas).
The remote test option will use Zoom for online supervision of the tests and you must be able to use Zoom with a camera, microphone, and screen-sharing. Students who will need to use the remote test option must contact the course coordinator in the first two weeks to get permission and make arrangements.
SWEN 430 looks at a range of issues relating to the modern compiler engineering. In particular, the course will focus on techniques and algorithms for code generation, code optimisation and type checking. During the course projects, students will develop a fully-fledged compiler for a small imperative language. Students should expect to learn a great deal about how compilers work and, in particular, about the Java Bytecode and x86 instruction sets.
The aim of this course is to introduce the ideas, techniques and algorithms which form the foundation of modern compilers. The course has a practical focus and students will develop their compiler in the Java language. If you have concerns about whether your Java skills are sufficient, you should speak to the course coordinator as soon as possible.
Withdrawal from Course
Withdrawal dates and process:
This course will be offered in-person and online. For students in Wellington, there will be a combination of in-person components and web/internet based resources. It will also be possible to take the course entirely online for those who cannot attend on campus, with all the components provided in-person also made available online.
During the trimester there will be two lectures per week.
Student feedback on University courses may be found at: www.cad.vuw.ac.nz/feedback/feedback_display.php
Dates (trimester, teaching & break dates)
- Teaching: 05 July 2021 - 08 October 2021
- Break: 16 August 2021 - 29 August 2021
- Study period: 11 October 2021 - 14 October 2021
- Exam period: 15 October 2021 - 06 November 2021
Set Texts and Recommended Readings
There is no set text for SWEN 430, but the following book contains most of the material presented in this course and is on closed reserve in VUW Library:
- Modern Compiler Implementation in Java, Andrew Appel. (closed reserve)
Other books of interest include:
- Engineering a Compiler, Keith D. Cooper and Linda Toczon. See Chapter 8. [1 copy in library]
- Compilers: Principles, Techniques and Tools, Alfred V. Aho, Ravi Sethi and Jeffrey D. Ullman. See Chapter 10. [1 copy in library]
- Advanced Compiler Design and Implementation, Steve S. Muchnick. See Chapter 9.
- Optimizing Compilers for Modern Architectures, Randy Allen and Ken Kennedy. See Chapter 4.4 and 11.
Mandatory Course Requirements
In addition to achieving an overall pass mark of at least 50%, students must:
- Achieve at least 40% average across all of the assignments, and
- Achieve at least 40% in the final test, to demonstrate achievement of all the CLOs of the course.
If you believe that exceptional circumstances may prevent you from meeting the mandatory course requirements, contact the Course Coordinator for advice as soon as possible.
|Assessment Item||Due Date or Test Date||CLO(s)||Percentage|
|Assignment 1||CLO: 1,2||10%|
|Assignment 2||CLO: 1,3,4||15%|
|Assignment 3||CLO: 1,4,5||15%|
|Assignment 4||CLO: 1,4,5||20%|
Late submissions will incur an automatic penalty of 10% of the final mark per day. Submission between 0 and 24 hours late will be counted as one day late; those betwee 24 and 48 hours late will be counted as two dates late, etc. Any request for an extension must be made to the lecturer in charge prior to the due date. Any extensions requested on the basis of medical grounds must be supported by a doctor's certificate.
If you anticipate difficulty in meeting a deadline, please approach the course coordinator as soon as possible so an extension can be agreed upon.
Submission & Return
Work for marking should be submitted electronically using the ECS Submission System. Marked projects will be available at lectures, or from the School Office.
In order to maintain satisfactory progress in SWEN 430, you should plan to spend an average of 10 hours per week on this paper. A plausible and approximate breakdown for these hours would be:
- Lectures: 2 hours,
- Readings: 3 hours,
- Assignments: 5 hours.
Communication of Additional Information
All online material for this course can be accessed at https://ecs.wgtn.ac.nz/Courses/SWEN430_2021T2/
Links to General Course Information
- Academic Integrity and Plagiarism: https://www.wgtn.ac.nz/students/study/exams/integrity-plagiarism
- Academic Progress: https://www.wgtn.ac.nz/students/study/progress/academic-progess (including restrictions and non-engagement)
- Dates and deadlines: https://www.wgtn.ac.nz/students/study/dates
- Grades: https://www.wgtn.ac.nz/students/study/progress/grades
- Special passes: Refer to the Assessment Handbook, at https://www.wgtn.ac.nz/documents/policy/staff-policy/assessment-handbook.pdf
- Statutes and policies, e.g. Student Conduct Statute: https://www.wgtn.ac.nz/about/governance/strategy
- Student support: https://www.wgtn.ac.nz/students/support
- Students with disabilities: https://www.wgtn.ac.nz/st_services/disability/
- Student Charter: https://www.wgtn.ac.nz/learning-teaching/learning-partnerships/student-charter
- Terms and Conditions: https://www.wgtn.ac.nz/study/apply-enrol/terms-conditions/student-contract
- Turnitin: http://www.cad.vuw.ac.nz/wiki/index.php/Turnitin
- University structure: https://www.wgtn.ac.nz/about/governance/structure
- VUWSA: http://www.vuwsa.org.nz
Offering CRN: 18668
Prerequisites: COMP 261 or SWEN 324 (or 224); 30 further 300-level points from (COMP, NWEN 303, SWEN)
Duration: 05 July 2021 - 07 November 2021
Starts: Trimester 2