0% found this document useful (0 votes)
44 views2 pages

Compiler Design PYQP

Uploaded by

Vagisha Soni
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
44 views2 pages

Compiler Design PYQP

Uploaded by

Vagisha Soni
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Total No.

of Printed Pages 02
Total No. of Questions: 05
RollNo. 20100BIBDAL01223
BTCSIBM601
B.Tech. (CSE-BDAI/ CSE-DSI)
VIISemester Examination, December 2023
Fundamental of Compiler Design
Choice Based Credit System (CBCS)
Maximum Marks: 60
Time: 3 Hrs.
Minimum Pass Marks: 24

and part C' carTies 6 marks.


Note: (1) All questions carry equal marks, out of which part 'A' and 'B carry 3 marks
(2) From each question, part 'A'and 'B' are compulsory and part 'C' has internal choice.
(3) Draw neat diagram, wherever necessary.
(4) Assume suitable data wherever necessary.
03
Q.1(AY Explain the phases of Compiler with a diagram.
(B Describe input Buffering. Also explain Single Buffering and Double Buffering Schemes. 03
(9 What is LEX? Describe auxiliary definitions and translation rules for LEX with suitable
examples. Give a short description on "LEX" tools. 06

OR

Differentiate between Single Pass and Multi-Pass Compiler.

Q.2(AY Explain the leftmost and rightmost derivations with suitable examples. 03

1 B) Differentiate between Parse tree and Syntax tree with example. 03

C Write a short note: 06

(a) YACC
(b) Ambiguous Grammar
OR

Consider the following Grammar and Construct the LL(1) Parser:


S-> iEtSS' |a
S'> es |8
E -> b

03
Q.3/A) What is Syntax Directed Definition? Also. explain its roles in translation.
(Synthesized) and L-attribute Definitions
Y Differentiate between S-attribute Definitions 03
(Inherited).
Contd........

1
Construct Three address code for following statements: 06
do
X=y+z
while x<20
OR

Construct Three address code for following statements:


for(i=1;i<20,i++)

X=X+1

03
Q.4A llustrate optimization techniques with suitable examples.
03
(BY Describe Quadruples, Triples with suitable example.
06
(C) Construct DAGfor followingstatement:
a=b *minus c + b* minus c
OR

Explain the working of Error Handler. Also explain Error detection and recovery mechanisms.
03
Q.5A) Expiain the challenges of the design of target code generation.
B llustrate about the various data structures used in Runtime Storage management. 03

(C) Describe how Giobal Data Flow Analysis is useful for code optimization. 06

OR
tAlustrate why Peephole Optimization is useful for target code optimization.

XXXXXXX

You might also like