# Software Analysis Midterm
###### tags: `class`
## Augmented Control Flow Graph
Add start, entry and exit, where start is the parent of entry and exit
## Dominant tree and post dominant tree
- Dominator tree: start from entry
- Post dominator tree: start from exit

## Control dependece graph
https://collab.its.virginia.edu/access/content/group/f7c3f065-5457-4a72-a314-d7209736a27b/Solutions%20to%20assignments/problem4%20-soln.pdf
1. augment CDG
1. find S, a set of edges (A,B) in ACFG such that B is not an ancestor in PDT
2. for each edge (A,B) in S, find L, the least common
ancestor of A and B in PDT
3. consider each edge (A,B) in S and its corresponding L.
Traverse backwards in the PDT from B to L, marking each
node visited; mark L only if L = A
4. Statements representing all marked nodes are control
dependent on A with the label that is on the edge (A,B).
## program slicing
http://www.cs.cmu.edu/afs/cs/academic/class/17654-f01/www/lecture/14.pdf






## SDG
Enter functionname
copy the parameters and return value

