Compiler Put
Compiler Put
Section-A
Section-B
2) Answer any six questions. Each question carries equal marks. (6*5=30)
a) What is Compiler? Explain all the necessary phases and passes in a Compiler Design.
b) Consider the Grammar
S ->( L) | a
L ->L,S|S
Find parse tree for the following string
(i) (a,(a,a))
(ii) (a,((a,a,)(a,a,)))
c) Translate the expression
–(a+b)*(c+d)+(a+b+c) into Quadruples, Triples and Indirect Triples
d) Find the LEADING and TRAILING of the grammar
A->AcB |cC |C
B ->bB |id
C-> c|€
e) Discuss Symbol Table and various data structures for symbol table.
f) What is Cross Compiler? Discuss Bootstrapping with example.
g) Explain Loop Optimization and various methods of loop optimization.
h) Define Runtime Storage Organization.
Section-C