Top Banner
Compiler Design Course Overview Hwansoo Han
12

Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

May 30, 2018

Download

Documents

lylien
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Compiler Design

Course Overview

Hwansoo Han

Page 2: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Compiler

Class web page

Lecture slides

http://arcs.skku.edu/Courses/Compilers

Project handouts, ...

http://www.icampus.ac.kr

Instructor: Hwansoo Han

TA

Grad Students @ARCS (#85565)

2

Page 3: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Prerequisites

Prerequisite Courses

Data Structure

System Programming

Algorithms

Automata Theory

Computer Architectures

Programming Languages

Programming Skill

C/C++

Programming in Linux environment (gcc, gdb, vi/emacs, ...)

3

Page 4: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Textbook & References

Textbook

Engineering a Compiler (2nd Ed.)

References

Compilers – Principles, Techniques,

and Tools (2nd edition)

Flex & bison (linux version of Lex & Yacc)

Online manual (URLs in class webpage)

4

Page 5: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Grading

Exams

Midterm 30%

Final 30%

Programing Assignments 30%

Front-End

Data Flow Analysis

Misc. 10%

Homework & quiz

Attendance

5

Page 6: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Grading Policy

Must – otherwise you will get ‘F’ grade

Take midterm and final exams

Submit all two phases of programming assignments

Attend 13 weeks and more

May

Be absent from 3 classes (No-Need-To-Ask)

From the 4th absence, it will be reflected on your final grade

Not submit homework, but it will be reflected on your final grade

Not take quizzes, but it will be reflected on your final grade

6

Page 7: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Topics

Overview

Scanning & Parsing

Context Sensitive Analysis

Intermediate Representation

Inner Workings of Compiled Code

Optimizations

Data flow Analysis

Instruction Selection & Scheduling

Register Allocation

7

Page 8: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Why Study PLs and Compilers?

Learn system software intimately interconnected with

Architecture, Systems,

Programming methodology, and Language design

Expose to practical algorithmic & engineering issues

“Theory and practice are not mutually exclusive; they are

intimately connected. They live together and support each other.”

[D. E. Knuth, 1989]

Compilers

8

Page 9: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

What is a Compiler?

What is a compiler?

executable program → executable program

in another language

improve the program in some way

9

Compilersourceprogram

targetprogram

input

output

Page 10: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Many Forms of Translation

Interpretation

Hybrid of compilation and interpretation

10

Page 11: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

Compiler Technology

Compiler Technology = Off-Line Processing

Goals:

Improving performance

Making it practical to use the full power of the language

Trade-off: preprocessing time vs. execution time (or space)

For end-users:

Acceptable performance of both compiler and application

11

Page 12: Course Overview - ARCS ? Main/Home Page?arcs.skku.edu/pmwiki/uploads/Courses/Compilers/00-Overview.pdf · Compiler Design Course Overview Hwansoo Han. Compiler Class web page ...

To-do-list

Get your programming project partners

Team up with 2 students in a group

Get programming environment

Linux machines

Check if “flex” and “bison” installed

12