Q12
Consider the following intermediate program in three address code
p = a - b
q = p * c
p = u * v
q = p + qWhich one of the following corresponds to a static single assignment form of the above code?
Show answer without attempting
Answer: B
GATE CS · 5 questions
5 Compiler Design questions from GATE CS papers (2017), each with the official answer key. Answer any question right here and it is marked straight away, or practise them one at a time.
p = a - b
q = p * c
p = u * v
q = p + qAnswer: B
stmt -> if expr then expr else expr; stmt | ε
expr -> term relop term | term
term -> id | number
id -> a | b | c
number -> [0-9]if e1 then e2 else e3Answer: 1024.0
Answer: C
Answer: A
Answer: C
0/50 correct0 marks