CS-603 · Compiler Design/Unsolved PYQ Paper
CS-603 Compiler Design - May 2023 Question Paper
-
8 MarksaDraw the structure of a compiler and describe various phases in the compilation process. Mention the output of the following statement: $id_1=id_2+id_3*50$ at each phase.
-
6 MarksbDesign the LEX program that recognizes the tokens of a C language and returns the token found.
-
14 MarksCompute LR(0) items for the following grammar and construct SLR Parser table. $S \rightarrow L=R | R$ $L \rightarrow *R | id$ $R \rightarrow L$
-
7 MarksaDifferentiate between Top down parsing and Bottom up parsing.
-
7 MarksbConstruct the Recursive Descent Parser with back tracking for the following grammar $S \rightarrow aSbS | bSaS | \epsilon$
-
10 MarksaHow is Stack storage allocation strategy different from heap allocation strategy? Describe them and mentioning their merits and demerits.
-
4 MarksbExplain different Polymorphic functions with suitable examples.
-
8 MarksaExplain in brief about different sources of optimization of basic blocks with suitable example.
-
6 MarksbDefine flow graph? Explain how a program is converted into a flow graph.
-
8 MarksaWhat is DAG? Construct DAG for the following basic blocks: $D := B*C; E := A+B; B := B+C; A := E-D;$
-
6 MarksbDifferentiate between S-attribute with L-attribute definition with suitable example.
-
8 MarksaExplain in brief about equivalence of type expression.
-
6 MarksbDiscuss about peephole optimization.
-
14 MarksWrite a short note on following: a) Common sub-expression elimination b) Register allocation c) Three address code
Go to where you left off?
Quick Add to Notes
Save questions, your own notes and screenshots into notes filed by unit. It takes a free account.
Create free accountHave an account? Log in
Notes Panel