College of Science

Courses

Compilers

Course Code C0670 Th 4 Pr 4 CrHrs 3

 Explaining how scanner, parser, and type checker are implemented to validate the given source code, in detail. Therefore, different concepts will be used in this course such as RE, grammar, and different types of parsers.

This course aims to explain the main phases of a compiler. It also makes students understand the compiler design and write some programs (Using Visual C#) that represented the basic functionalities of the analysis part of the compiler

Distribution of Marks

Final Mark

Final Exam

Second Term

Mid-Year

First Term

100

Prac.

Theor.

Prac.

Theor.

Prac.

Theor.

Prac.

Theor.

20

30

5

5

10

20

5

5

References

SN

Jorgensen, T. Æ. (1999). Basics of Compiler Design, Kurumba 5 Dat1E.

1

Alfred V. Ahom, Monica S. Lam, Ravi Sethi, and Jeffrey D. Ullman “Compilers: Principles, Techniques, and Tools”, 2nd edition, Addison-Wesley, 2006.

2

Subject

Week

What is a Compiler, Analysis Software Tools

First

Introduction to lexical analyzer

Second

Tokens , Patterns and Lexemes

Third

The Role of Parser, Ambiguity

Fourth

Eliminating Ambiguity, Eliminating Left Recursion

Fifth

Eliminating Left Factoring, LL(1) grammar

Sixth

Non-recursive Predicative Parser

Seventh

LL(1) parser

Eighth

FIRST and FOLLOW Functions

Ninth

Construction of LL(1) parsing table

Tenth

Error Recovery in Predictive Parsing

Eleventh

Bottom-up Parsing, Handles

Twelfth

LR Parser Types

Thirteenth

Examples of LR(0)

Fourteenth

General Examples

Fifteenth