13
S C I E N C E P A S S I O N T E C H N O L O G Y www.tugraz.at Dr. Birgit Hofer, Univ.-Prof. Dr. Franz Wotawa Institute for Software Technology Compiler Construction (1 Design practical) 716.077 SS 2015

Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Embed Size (px)

Citation preview

Page 1: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

1

S C I E N C E P A S S I O N T E C H N O L O G Y

www.tugraz.at

Dr. Birgit Hofer, Univ.-Prof. Dr. Franz Wotawa Institute for Software Technology

Compiler Construction (1 Design practical) 716.077 SS 2015

Page 2: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

2

Overview

• Assignments • 3 theoretical assignments (10 points each, 30 % influence on grade)

• Programming assignment with 4 parts (70 % influence on grade)

• Additional (bonus) assignments

• Team work • Up to 4 students/group (Teams of 4 are recommended)

• Electronic registration system (10.3.-20.3.)

• Notification of achieved points • Via eMail

• In case of questions Question hours / newsgroup

Page 3: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

3

Theoretical assignments

• Delivery box

(in front of the IST

secretary’s office)

• Cover sheet

Page 4: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

4

Hints for the assignments

• Check if a solution could be found

• If no solution could be found, explain why

• Start early

• If you have questions, ask them (Newsgroup, question hour)

Page 5: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

5

Questions

• Newsgroup : tu-graz.lv.cb

• Mails: [email protected]

• Question hour

• Lecture: Prof. Wotawa – Dienstag, 13-14 Uhr

• Practical: Birgit Hofer – Mittwoch 13-14 Uhr

• Question hour

• In the lecture

Page 6: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

6

Programming assignment

Simple Mathematical Compiler

Page 7: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

7

Calculator

Page 8: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

8

Calc input program

Java Bytecode

Compiler Phasen

Page 9: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

9

Parts of the assignment

• Task 1: Lexer + Parser

• Task 2: Type Checking

• Task 3: Intermediate Code

• Task 4: Byte Code

• Bonus points for grammar enhancements • Forward Declarations • Nested scoping • Short-circuit evaluation

Page 10: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

10

Delivery of programming tasks 1 • Via SVN folder: (task_1, ...) • Keep to the given structure

• File names

• Methods and class names

• See Framework

• Readme file • Work spend per team member– in percentage

• Implemented bonus tasks

Page 11: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

11

Delivery of programming tasks 2

• If you could not solve a task

Ask via eMail for a sample solution

• Feedback in question hours possible

Ask the teaching assistants for feedback

• Mandatory interviews

Page 12: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

12

Theoretical assignments Delivery due to

Assignment 1 March, 20th 12 pm (noon) Assignment 2 March, 27th 12 pm (noon) Assignment 3 April, 24th 12 pm (noon)

Programming assignment Delivery due to Task 1 (Lexer + Parser) March, 27th 12 pm (noon) Task 2 (Type Checking) April, 24th 12 pm (noon)

Task 3 (Intermediate Code) May, 8th 12 pm (noon) Task 4 (Byte Code) May, 22nd 12 pm (noon) Interviews May, 22nd 1 pm to 6 pm

Important dates

Page 13: Compiler Construction (1 Design practical) · PDF fileDesign practical Compiler Construction 2 • Overview • Assignments 3 theoretical assignments (10 points each, 30 % influence

Design practical Compiler Construction

13

Question hours and tutorials Date and time Programming assignment: Tutorial Lexer + Parser

March, 9th 3 pm

Assignment 1: Question hour Programming assignment: Question hour (Lexer + Parser)

March, 16th 3 pm

Programming assignment: Question hour (Lexer + Parser) Assignment 2: Question hour Programming assignment: Tutorial Type Checking + Intermediate Code

March, 23rd 3 pm

Assignment 3: Question hour Programming assignment: Question hour (Type Checking, Intermediate Code) Tutorial Code Generation

April, 20th 4 pm

Programming assignment: Question hour (Code Generation)

May, 18th 4 pm