The Gateway to Computer Science Excellence
0 votes
149 views
CAN ANYONE PLEASE EXPLAIN WHAT IS SSA I AM NOT UNDERSTANDING THAT CONCEPT ANYWHERE!!!! NOT EVEN THERE IN ULLMAN
in Compiler Design by Active (3.7k points) | 149 views

1 Answer

+6 votes
Best answer

In simple terms , SSA means single state assignment and is useful for the purpose of compiler optimisations .

In simple words , in SSA , we assign to a particular variable only once . Once a variable is assigned , it is not reassigned later .

As an example  : 

p   =   q + r

q   =   r + s

s   =   t + u

p   =  s  + v

r    =  p + t

Now we can see 'p' is assigned twice here and rest are assigned once . So to make it into SSA form , we need to re write the last two productions accordingly because 'r' is assigned after 'p' is reassigned so 'r' is dependent on 'p' which is re assigned.

Hence the last two lines of the code will be re written as : 

x  =  s + v

r   =  x + t

by Veteran (102k points)
selected by
0
@ Habibkhan brother please suggest a place to study about register allocation and graph couring and spilling

thanks a lot for answering

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,647 questions
56,492 answers
195,439 comments
100,695 users