Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Hcurs: E+E+T/T

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Reg. No.

136 S L4
FOUR YEAR B.TECH. DEGREE EXAMINATION _ APRIL, z}rc.
SIXTH SEMESTER EXAMINATION
COMPUTER SCIENCE AND ENGINEERiNG
COMPILER DESIGN (CD)
(scHEME - 2013)

Time : 3 Hcurs Max. Marks : 70

Note : Question No. 1 is compulsory and it must be answered first in Seq.r"rr"e ut


one piace only.

Answer any FOUR from the remaining.

Question No. 1 carries 10 rnarks and remaining questions carry 15 marks each.

1. (a) Define the term Lexeme.


(b) What is the difference between phase and pass.
Gr What is an Ambiguous grammar?
(d) What is the role of a parser? !
(e) Define Back patching.
(0 Define Fiow graph
(g) Differentiate between basic block and flow graph.
(h) What is global data flow analysis?
(i) What is the use of algebraic identities in optimization of basic blocks?
0) Define Peephoic.
c)
(a) Explain the need for grouping the phases of compiler. (6)

(b) Briefly explain about compiler construction tools. (9)

D. (a) analyser'
Explain the language for specifying lexicai (10)

(b) What is the need and role of lexical analyzer? (5)

4. (a) Construct SLR parsing table for the grammar. (10)

E+E+T/T
T-+T*F/F
I'+ (E)/id

(b) Compare and contrast SLR, CLR and I"ALR parsers. (5)

Turn Over
5. (a) Explain the specification of simple type checker. (5)
(b) What are the different strategies for storage allocation? Expiain. (10)

6. (a) Explain the terms local optimization and loop optirnization. (8)
(b) Generate the three address code for the Boolean expression o < b or c < d,
ande<f . (7)

7. (a) What are the difficulties with code generaticn? (6)


(b) Write simple code generation Algorithm and generate the code for
a:=b+s*(d,_e). (e)

, 136 s 14

You might also like