retagged by
513 views
1 votes
1 votes
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 expression
a*b + c/d + e-f is .??

( Can anyone explain how the answer is 16???  )
retagged by

1 Answer

Best answer
1 votes
1 votes
t1=a*b;

t2=c/d;

t3=t1+t2;

t4=t3+e;

t5=t4-f;

 

5 temporary variables used while 6 are already there (a,b,c,d,e,f)

total variables=11;

sum of temporary and total=5+11=16
selected by
Answer:

Related questions

1 votes
1 votes
2 answers
1
A_i_$_h asked Sep 7, 2017
597 views
Consider the following code segmenta= b - cd = a + da = d + ed = c * fd = a * dthe min number of total variables required to convert the above code segment to static sing...
10 votes
10 votes
1 answer
2
2 votes
2 votes
1 answer
3
0 votes
0 votes
1 answer
4
minal asked Jan 22, 2019
937 views
# of temporary variable required to create 3 address code in static single assignment form for the expression P+Q*R-S/(Q*R).