retagged by
596 views
1 votes
1 votes
Consider the following code segment

a= b - c

d = a + d

a = d + e

d = c * f

d = a * d

the min number of total variables required to convert the above code segment to static single assignment form is _____________
retagged by

2 Answers

1 votes
1 votes
For Static Single Assignment:

A0=B0-C0;

D0=A0+D1;

A2=D0+E0;

D3=C0*F0;

D4=A0*D3;

So total number of variables: A0,B0,C0,D0,D1,D2,D3,D4,E0,F0. So total 10 variables.
0 votes
0 votes
Is ans is 11

Related questions

10 votes
10 votes
1 answer
1
1 votes
1 votes
1 answer
2
atul_21 asked Jul 8, 2017
513 views
The sum of least number of temporary variables and total variables required to create a three address code in single static assignment form for the expressiona*b + c/d + ...
2 votes
2 votes
1 answer
3
1 votes
1 votes
5 answers
4
Sambhrant Maurya asked Oct 31, 2018
2,947 views
Consider the following code generation:a=b+c;c=a+x;d=b+c;b=a+x;The minimum no. of total variables required to convert the above code to static single assignment form is__...