1. A DAG for a basic block is a directed cyclic graph that represents the computation in the basic block.
2. The nodes are labeled with operators or unique identifiers, with leaves labeled by variable names or constants and interior nodes labeled by operators.
3. The nodes optionally include sequence identifiers to represent the "current" value of a variable as it is computed through the basic block.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
204 views3 pages
DAG Representation of Basic Blocks
1. A DAG for a basic block is a directed cyclic graph that represents the computation in the basic block.
2. The nodes are labeled with operators or unique identifiers, with leaves labeled by variable names or constants and interior nodes labeled by operators.
3. The nodes optionally include sequence identifiers to represent the "current" value of a variable as it is computed through the basic block.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 3
DAG Representation of Basic blocks
A DAG for a basic block is a directed cyclic graph
with the following labels on nodes: 1.Leaves are labeled by unique identifiers, either variable names or constants. From the operator applied to a name we determine whether the lvalue or r-value of a name is needed; most leaves represent r-values. The leaves represent initial values of names, and we subscript them with 0 to avoid confusion with labels denoting current values of names as in (3) below. 2.Interior nodes are labeled by an operator symbol. 3.Nodes are also optionally given a sequence of identifiers for labels. The intention is that interior nodes represent computed values, and the
DAG Representation of Basic blocks
1. t1 := 4 * i 2. t2 := a[t1] 3. t3 := 4 * i 4. t4 := b[t3] 5. t5 := t2 * t4 6. t6 := prod + t5 7. prod := t6 8. t7 := i + 1 9. i := t7 10.if i <= 20 goto (1)