KTU 2024 Scheme · Semester 5 · Program Elective II — Artificial Intelligence and Machine Learning
Introduction to Compiler Design (PECMT527) Syllabus
Official KTU 2024 Scheme syllabus for Introduction to Compiler Design, Semester 5, Program Elective II — Artificial Intelligence and Machine Learning (Artificial Intelligence and Machine Learning).
Course Code
PECMT527
Credits
3
Teaching Hours
3:0:0:0 (L:T:P:R)
CIE Marks
40
ESE Marks
60
Exam Duration
2 Hrs. 30 Min.
Prerequisites
None
Semester
Semester 5
Course Objective
To give a comprehensive understanding of the compiler construction process, including lexical analysis, parsing, semantic analysis, code generation, and optimization. To enable the learner to design, implement, and test a compiler for a simple language, utilizing tools including LEX and YACC for lexical analysis and parsing, respectively. To learn to use code optimization techniques to improve the efficiency of generated code.
Module-wise Syllabus
Module 1
10 contact hoursCompilers - The Translation Process, Major Data Structures, Other Issues, Bootstrapping and Porting. Scanning Process - Finite state automata and Regular expressions (Basic idea only). Use of LEX to generate automatic scanners (basic idea only). Parsing Process - Context free Grammars (Basic idea only), Parse Trees and Abstract Syntax Trees, Ambiguity.
Module 2
10 contact hoursTop-down Parsing - Recursive Descent, LL(1), First and Follow. Error Recovery in Top-down Parsers. Bottom-up Parsing - Overview of Bottom -up parsing, Shift-reduce parser, LR(0) Items and LR(0) Parsing, SLR(1) parsing, General LR(1) and LALR(1) Parsing.
Module 3
8 contact hoursSemantic Analysis: Attributes and attribute grammars. Dependency graphs and Evaluation order, Synthesized and Inherited attributes. Intermediate code generation - Three address code, P - code. Intermediate code as a synthesized attribute.
Module 4
10 contact hoursGeneration of Target code from intermediate code - Code generation of Data structure references- address calculation, array references, if and while statements. Code Optimization Techniques: Principal sources of code optimization, Classification of optimizations, Data Structures and Implementation Techniques for Optimizations.
Course Outcomes
- CO1Explain lexical analysis techniques to build a scanner for a given language specification.
- CO2Construct parse trees for input programs using parsing algorithms and detect syntactic errors.
- CO3Develop semantic analysis techniques to check program correctness.
- CO4Develop intermediate code representations by applying intermediate code generation techniques.
- CO5Utilize code optimization strategies to improve performance of the machine code.
Assessment Pattern (CIE: 40 marks, ESE: 60 marks)
Continuous Internal Evaluation (CIE)
| Attendance | 5 |
| Assignment / Microproject | 15 |
| Internal Examination 1 (Written) | 10 |
| Internal Examination 2 (Written) | 10 |
End Semester Examination (ESE)
Total 60 marks, 2 Hrs. 30 Min.. See the official KTU syllabus document for the exact Part A / Part B question pattern for this course.
Textbooks & Reference Books
Textbooks
- Compiler Construction - Principles and Practice — Kenneth C Louden (Cengage, 1/e, 2007)
Reference Books
- Compilers - Principles Techniques and Tools — Aho A.V., Ravi Sethi and D. Ullman. (Addison Wesley,, 2/e, 2013)
- Engineering a Compiler — Keith D. Cooper Linda Torczon (Morgan Kaufman, 3/e, 2023)
- Modern Compiler Implementation in C — Andrew W. Appel (Cambridge University Press, 2004)
- The Theory and Practice of Compiler Writing — Tremblay and Sorenson (Tata McGraw Hill, 1/e, 1984)
- System Programming and Operating Systems — D. M. Dhamdhere (Tata McGraw Hill, 2/e, 2001)
Frequently Asked Questions
How many credits is KTU Introduction to Compiler Design (PECMT527)?
3 credits, with 3:0:0:0 (L:T:P:R) teaching hours per week, under the KTU 2024 Scheme.
How many modules are in the PECMT527 syllabus?
4 modules, 38 total contact hours.
What is the CIE and ESE mark split for this course?
CIE (Continuous Internal Evaluation): 40 marks. ESE (End Semester Examination): 60 marks, 2 Hrs. 30 Min.. Total: 100 marks.
What are the recommended textbooks for PECMT527?
Compiler Construction - Principles and Practice (Kenneth C Louden).
Is this syllabus specific to one branch, or common to others too?
This Semester 5 course is listed under Program Elective II — Artificial Intelligence and Machine Learning at KTU under the 2024 Scheme — check the course header above for which branches it's common to.
Need help with KTU Introduction to Compiler Design?
Learnizo offers live, 1-on-1 online tuition for KTU AI&ML subjects — matched to your exact module and semester.