Build SSA graph from a given AST node based on the CFG.
| Method | __init__ |
No summary |
| Method | compute_ |
Compute dominating frontiers for each of blocks |
| Method | compute |
Compute immediate dominators for each of blocks |
| Method | compute_ |
Compute single static assignment form representations for a given CFG. During the computing, constant value and alias pairs are generated. The following steps are used to compute SSA representations: step 1a: compute the dominance frontier step 1b: use dominance frontier to place phi node if node X contains assignment to a, put phi node for an in dominance frontier of X adding phi function may require introducing additional phi function start from the entry node step2: rename variables so only one definition per name... |
| Method | get |
Undocumented |
| Method | get |
Extract all identifiers from the given AST node. |
| Method | get |
Extract the contextual information of each of identifiers. For assignment statements, the assigned values for each of variables will be stored. In addition, the del_set will store all deleted variables. |
| Method | print |
Undocumented |
| Method | to |
Undocumented |
| Instance Variable | block |
Undocumented |
| Instance Variable | block |
Undocumented |
| Instance Variable | dom |
Undocumented |
| Instance Variable | error |
Undocumented |
| Instance Variable | global |
Undocumented |
| Instance Variable | global |
Undocumented |
| Instance Variable | numbering |
Undocumented |
| Instance Variable | reachable |
Undocumented |
| Instance Variable | ssa |
Undocumented |
| Instance Variable | undefined |
Undocumented |
| Instance Variable | unreachable |
Undocumented |
| Instance Variable | var |
Undocumented |
Compute dominating frontiers for each of blocks
| Parameters | |
| ssa | blocks from a control flow graph. |
Compute immediate dominators for each of blocks
| Parameters | |
| ssa | blocks from a control flow graph. |
Compute single static assignment form representations for a given CFG. During the computing, constant value and alias pairs are generated. The following steps are used to compute SSA representations: step 1a: compute the dominance frontier step 1b: use dominance frontier to place phi node if node X contains assignment to a, put phi node for an in dominance frontier of X adding phi function may require introducing additional phi function start from the entry node step2: rename variables so only one definition per name
| Parameters | |
| cfg | a control flow graph. |
Extract the contextual information of each of identifiers. For assignment statements, the assigned values for each of variables will be stored. In addition, the del_set will store all deleted variables.
| Parameters | |
| stmt | statement from AST trees. |
| del | deleted identifiers |
| const | a mapping relationship between variables and their assigned values in this statement |