Phase 2: Building a dominator tree Goal: Build a dominator tree using the approach from the paper by Cooper et al., Software - Practice and Experience, 2001. Run your implementation on each CFG from Phase 1. Recall that in these CFGs, (1) every CFG node must be reachable from ENTRY, and (2) EXIT must be reachable from every CFG node. In the resulting tree, ENTRY is the root and EXIT is one of the leaves. Your implementation MUST use the 'doms' data structure described in the paper. As discussed in the paper, this data structure implicitly represents DOM sets - you should NOT represent such sets explicitly. Note that in this data structure, the nodes are represented by their postorder numbers - more precisely, a node is encoded by its "finishing time" from the standard DFS traversal algorithm. See the examples in the paper for more details. After computing the dominator tree for the CFG, calculate a set of numbers {count_0, count_1, count_2, ... }. count_0 is the number of nodes with 0 children in the dominator tree (i.e., the number of leaves). count_1 is the number of nodes with 1 child in the dominator tree. In general, count_k is the number of nodes with k children in the tree. Obviously, there exists some point after which count_k = 0 (for sufficiently large k). Compute the counts only up to the largest non-zero value. As a sanity check, make sure that the sum of all counts is equal to the number of nodes in the CFG. Once all CFGs are processed and their individual sets {count_0, count_1, count_2, ... } are computed, add all count_0 values for all CFGs to obtain a single number COUNT_0 for the entire program. Similarly, compute COUNT_1, COUNT_2, etc. By 11:59 pm on Tuesday, October 19, submit the source code together a single text file report.txt containing: COUNT_0: ... COUNT_1: ... COUNT_2: ... ... all the way up to the largest non-zero COUNT_k. Submit your project using something like submit c788ac lab2 MyTransform.java MyTreeBuilder.java ... report.txt IMPORTANT: As with Phase 1, the code MUST be anonymized.