Overview of the Course Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University.

Slides:



Advertisements
Similar presentations
1 CIS 461 Compiler Design and Construction Fall 2014 Instructor: Hugh McGuire slides derived from Tevfik Bultan, Keith Cooper, and Linda Torczon Lecture-Module.
Advertisements

Compiler Construction by Muhammad Bilal Zafar (AP)
CIS 101: Computer Programming and Problem Solving Lecture 8 Usman Roshan Department of Computer Science NJIT.
Reasons to study concepts of PL
ISBN Chapter 1 Preliminaries. Copyright © 2004 Pearson Addison-Wesley. All rights reserved.1-2 Chapter 1 Topics Motivation Programming Domains.
Java for High Performance Computing Jordi Garcia Almiñana 14 de Octubre de 1998 de la era post-internet.
The Procedure Abstraction Part I: Basics Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412.
Lecture 36: Programming Languages & Memory Management Announcements & Review Read Ch GU1 & GU2 Cohoon & Davidson Ch 14 Reges & Stepp Lab 10 set game due.
Programming Languages Structure
ISBN Lecture 01 Preliminaries. Copyright © 2004 Pearson Addison-Wesley. All rights reserved.1-2 Lecture 01 Topics Motivation Programming.
From Cooper & Torczon1 Implications Must recognize legal (and illegal) programs Must generate correct code Must manage storage of all variables (and code)
Compiler Construction
Wrapping Up Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved.
Introduction to Code Generation Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved.
Summer 02-03Programming Language Concepts1 Programming Language Concepts (CS 360) Lecture 1: Overview, Grammars, and Little Languages Jeremy R. Johnson.
ISBN Chapter 1 Topics Motivation Programming Domains Language Evaluation Criteria Influences on Language Design Language Categories Language.
Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Technology Education Copyright © 2006 by The McGraw-Hill Companies,
Introduction & Overview CS4533 from Cooper & Torczon.
Copyright © 1998 by Addison Wesley Longman, Inc. 1 Concepts of Programming Languages Chapter 1.
COP4020 Programming Languages
1 CS101 Introduction to Computing Lecture 19 Programming Languages.
Overview of the Course. Critical Facts Welcome to CISC 672 — Advanced Compiler Construction Instructor: Dr. John Cavazos Office.
CS 355 – Programming Languages
The Procedure Abstraction Part I: Basics Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412.
COMPSCI 322: Language and Compilers Class Hour: Hyer Hall 210: TThu 9:30am – 10:15am.
Lexical Analysis — Part II: Constructing a Scanner from Regular Expressions Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved.
Principles of Compiler Design
An Introduction to Programming and Object-Oriented Design Using Java By Jaime Niño and Fred Hosch Slides by Darwin Baines and Robert Burton.
JIT in webkit. What’s JIT See time_compilation for more info. time_compilation.
Chapter 1 Introduction Dr. Frank Lee. 1.1 Why Study Compiler? To write more efficient code in a high-level language To provide solid foundation in parsing.
Overview of the Course Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University.
Lexical Analysis - An Introduction Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at.
Lexical Analysis - An Introduction Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at.
Compiler course 1. Introduction. Outline Scope of the course Disciplines involved in it Abstract view for a compiler Front-end and back-end tasks Modules.
Copyright © 2007 Addison-Wesley. All rights reserved.1-1 Reasons for Studying Concepts of Programming Languages Increased ability to express ideas Improved.
WSMX Execution Semantics Executable Software Specification Eyal Oren DERI
13-November-2002cse Compilers © 2002 University of Washington1 Compilers CSE 413, Autumn 2002 Programming Languages
1 EECS 6083 Compiler Theory Based on slides from text web site: Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved.
CS 460/660 Compiler Construction. Class 01 2 Why Study Compilers? Compilers are important – –Responsible for many aspects of system performance Compilers.
Introduction to Code Generation Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice.
Data Structures and Algorithms Dr. Tehseen Zia Assistant Professor Dept. Computer Science and IT University of Sargodha Lecture 1.
Compiler Construction (CS-636)
1 HPJAVA I.K.UJJWAL 07M11A1217 Dept. of Information Technology B.S.I.T.
Lecture 02: Compiler Overview Kwangman Man ( SangJi University.
Sung-Dong Kim, Dept. of Computer Engineering, Hansung University Java - Introduction.
Concepts of Programming Languages Lecturer: Dr. Emad Nabil Lecture # 2.
COMP Compilers Lecture 1: Introduction
Introduction to Optimization
컴파일러 첫째주 2005/09/01 권혁철.
课程名 编译原理 Compiling Techniques
CISC 7120X Programming Languages and Compilers
Overview of the Course Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University.
Local Instruction Scheduling
Compiler Construction
Lexical Analysis - An Introduction
Introduction to Optimization
COMP Compilers Lecture 1: Introduction
Introduction to Code Generation
Wrapping Up Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University have explicit.
Lecture 02: Compiler Overview
The Procedure Abstraction Part I: Basics
The Last Lecture COMP 512 Rice University Houston, Texas Fall 2003
Overview of the Course Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University.
Introduction to Optimization
Lexical Analysis - An Introduction
CompSci 1: Principles of Computer Science Lecture 1 Course Overview
CISC 7120X Programming Languages and Compilers
Lecture 1 Runtime environments.
Reasons To Study Programming Languages
Presentation transcript:

Overview of the Course Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. Students enrolled in Comp 412 at Rice University have explicit permission to make copies of these materials for their personal use.

Class-taking technique for Cmp Sci 410/610 I will use projected material a lot  I will moderate my speed, you sometimes need to say “STOP” You should read the book  Not all material will be covered in class  Book complements the lectures You are responsible for material from class  The tests will cover both lectures and readings Cmp Sci 410/610 is not a programming course  Projects are graded on functionality more than style (results matter) It will take me time to learn your names ( please remind me )

Compilers What is a compiler?

Compilers What is a compiler?  A program that translates an executable program in one language into an executable program in another language  The compiler should improve the program, in some way What is an interpreter?

Compilers What is a compiler?  A program that translates an executable program in one language into an executable program in another language  The compiler should improve the program, in some way What is an interpreter?  A program that reads an executable program and produces the results of executing that program

Compilers What is a compiler?  A program that translates an executable program in one language into an executable program in another language  The compiler should improve the program, in some way What is an interpreter?  A program that reads an executable program and produces the results of executing that program C is typically compiled, Scheme is typically interpreted Java is compiled to bytecodes (code for the Java VM)  which are then interpreted  Or a hybrid strategy is used  Just-in-time compilation

Taking a Broader View Compiler Technology = Off-Line Processing  Goals: improved performance and language usability  Making it practical to use the full power of the language  Trade-off: preprocessing time versus execution time (or space)  Rule: performance of both compiler and application must be acceptable to the end user Examples  Macro expansion  PL/I macro facility — 10x improvement with compilation

Taking a Broader View Compiler Technology = Off-Line Processing  Goals: improved performance and language usability  Making it practical to use the full power of the language  Trade-off: preprocessing time versus execution time (or space)  Rule: performance of both compiler and application must be acceptable to the end user Examples  Macro expansion  PL/I macro facility — 10x improvement with compilation  Database query optimization

Taking a Broader View Compiler Technology = Off-Line Processing  Goals: improved performance and language usability  Making it practical to use the full power of the language  Trade-off: preprocessing time versus execution time (or space)  Rule: performance of both compiler and application must be acceptable to the end user Examples  Macro expansion  PL/I macro facility — 10x improvement with compilation  Database query optimization  Emulation acceleration  TransMeta “code morphing”

Why Study Compilation? Compilers are important system software components  They are intimately interconnected with architecture, systems, programming methodology, and language design Compilers include many applications of theory to practice  Scanning, parsing, static analysis, instruction selection Many practical applications have embedded languages  Commands, macros, formatting tags … Many applications have input formats that look like languages  Matlab, Mathematica Writing a compiler exposes practical algorithmic & engineering issues  Approximating hard problems; efficiency & scalability

Intrinsic interest  Compiler construction involves ideas from many different parts of computer science Artificial intelligence Greedy algorithms Heuristic search techniques Algorithms Graph algorithms, union-find Dynamic programming Theory DFAs & PDAs, pattern matching Fixed-point algorithms Systems Allocation & naming, Synchronization, locality Architecture Pipeline & hierarchy management Instruction set use

Intrinsic merit  Compiler construction poses challenging and interesting problems:  Compilers must do a lot but also run fast  Compilers have primary responsibility for run-time performance  Compilers are responsible for making it acceptable to use the full power of the programming language  Computer architects perpetually create new challenges for the compiler by building more complex machines  Compilers must hide that complexity from the programmer  Success requires mastery of complex interactions

Making Languages Usable It was our belief that if FORTRAN, during its first months, were to translate any reasonable “scientific” source program into an object program only half as fast as its hand-coded counterpart, then acceptance of our system would be in serious danger... I believe that had we failed to produce efficient programs, the widespread use of languages like FORTRAN would have been seriously delayed. — John Backus

About the instructor My own research  Compiling advanced features for advanced architectures  Garbage collection (automatic storage management)  Efficient simulation (think JIT compilation)  Automatic generation of compiler & simulator components  Automated proofs of some properties of programs  The (probably) chaotic nature of computer performance Thus, my interests lie in  Quality of generated code  Interplay between compiler and architecture  Run-time performance analysis  Dynamic performance improvement  Automatic processing of machine descriptions into tools  Performance measurement and methodology

Next set of slides The view from 35,000 feet  How a compiler works  What I (i.e., the author) think is important  What is hard and what is easy