Gujarat Technological UniversityWinter 2024 examination

GTU 3170701 Compiler Design (CD) Winter 2024 Question Paper & PDF

B.E. · Computer Engineering · Semester 7 · Subject code 3170701
Download official PDFView PDF here
Share with your class
Total
70 marks
To pass
23 marks (33%)
Duration
2.5 Hours 10:30 AM – 1:00 PM
Questions
5 with internal choice
No solutions on this paper yetNeed them for your exam? Ask once. Papers that students ask for are solved first, and we aim to add them within 24 hours.

19 of 25 questions on this paper were also asked in other years. 2 more are types of question GTU sets again with new data. Each is marked below with the years it appeared.See all 39 repeated 3170701 questions, most asked first

Q.1

14 Marks
(a)
3 marks
Differentiate the following terms
1)interpreter and compiler
2)parse tree and syntax tree
(b)
4 marksAsked in 4 of 7 papers
Explain input buffering technique

Also asked in Summer 2026 Q2a, Summer 2024 Q1b, Summer 2023 Q2b

(c)
7 marksAsked in 5 of 7 papers
Explain phases of compiler with an example

Also asked in Winter 2025 Q1c, Summer 2025 Q1c, Winter 2023 Q1c, Summer 2023 Q1c

Q.2

14 Marks
(a)
3 marksAsked in 2 of 7 papers
Explain lexeme, token and pattern with an example

Also asked in Summer 2023 Q1a

(b)
4 marksAsked in 4 of 7 papers
Explain left recursion with an example

Also asked in Summer 2026 Q1b, Summer 2024 Q3b OR, Winter 2023 Q2b

(c)
7 marks

Construct transition diagram for relational operators. Explain roles of assembler, loader, linker and preprocessor

(c)
7 marksSame type asked in 5 of 7 papers

Construct DFA without constructing NFA for the regular expression (a+b)*abb over input alphabets ∑ = {a,b}

Also asked in Winter 2025 Q2c OR, Summer 2024 Q2c, Winter 2023 Q2c, Summer 2023 Q2c

Q.3

14 Marks
(a)
3 marksAsked in 4 of 7 papers
Compare top down and bottom up parsing

Also asked in Summer 2026 Q3a OR, Summer 2025 Q5a OR, Summer 2023 Q3b OR

(b)
4 marksAsked in 3 of 7 papers
Explain left factoring of grammar with an example

Also asked in Winter 2025 Q2b, Summer 2025 Q1b

(c)
7 marksAsked in 2 of 7 papers
Design LL
1)parsing table for the following grammar E → E + T | T
2)T →T*F | F
3)F → (E) | id

Also asked in Winter 2025 Q3c OR

(a)
3 marksAsked in 2 of 7 papers
Explain operator precedence parsing

Also asked in Winter 2025 Q3c

(b)
4 marksAsked in 4 of 7 papers
Explain ambiguous grammar with an example

Also asked in Summer 2026 Q3a, Winter 2025 Q3b, Summer 2023 Q2a

(c)
7 marksSame type asked in 2 of 7 papers
Design LALR parsing table for the following grammar
S → CC C → cC | d

Also asked in Summer 2026 Q3c

Q.4

14 Marks
(a)
3 marksAsked in 3 of 7 papers
Explain flow graph with suitable example

Also asked in Winter 2025 Q5a OR, Winter 2023 Q4a OR

(b)
4 marks
Draw annotated tree for an arithmetic expression 9+5-2
(c)
7 marksAsked in 6 of 7 papers
Briefly explain error recovery strategies

Also asked in Summer 2026 Q4b, Winter 2025 Q4c, Summer 2025 Q4b, Summer 2024 Q2b, Summer 2023 Q4b OR

(a)
3 marksAsked in 4 of 7 papers
Explain symbol table

Also asked in Winter 2025 Q4a, Summer 2025 Q5b OR, Summer 2023 Q4b

(b)
4 marksAsked in 3 of 7 papers
Write a short note on syntax directed definition

Also asked in Winter 2025 Q3b OR, Summer 2024 Q3b

(c)
7 marksAsked in 4 of 7 papers
Explain Quadruples, Triple, Indirect Triple with an example

Also asked in Summer 2026 Q4c, Summer 2025 Q4c, Winter 2023 Q4c

Q.5

14 Marks
(a)
3 marks
Explain stack allocation strategy
(b)
4 marksAsked in 5 of 7 papers
Explain various parameter passing methods

Also asked in Summer 2026 Q5b OR, Summer 2025 Q4b OR, Summer 2024 Q4a OR, Summer 2023 Q5b OR

(c)
7 marksAsked in 4 of 7 papers
Explain peephole optimization technique

Also asked in Summer 2026 Q4b OR, Winter 2025 Q4a OR, Summer 2025 Q5c OR

(a)
3 marksAsked in 3 of 7 papers
Compare: static v/s dynamic memory allocation

Also asked in Summer 2026 Q5a OR, Summer 2023 Q5b

(b)
4 marksAsked in 6 of 7 papers
Explain activation record

Also asked in Summer 2026 Q4a OR, Winter 2025 Q4b OR, Summer 2024 Q5a, Winter 2023 Q4a, Summer 2023 Q4a

(c)
7 marksAsked in 4 of 7 papers
Explain any three code optimization techniques in detail

Also asked in Summer 2024 Q5c, Winter 2023 Q5c, Summer 2023 Q5c

More Compiler Design papers

Questions repeat across sessions. Working through two or three papers shows you which topics GTU asks most.

Preparing with friends?

Send this paper to your class group. Every question has its own link.

About this paper

Official Gujarat Technological University (GTU) examination paper for Compiler Design (CD) (Winter 2024, B.E. · Computer Engineering, Sem 7). Features complete 70-mark regular & remedial examination pattern, official marking distribution across all 5 questions, and direct 1-click official PDF download.

Transcribed for student exam preparation from Gujarat Technological University official examination archives. Questions, syllabus guidelines, and curriculum marking schemes remain the intellectual property of Gujarat Technological University.

ViewDownload PDF