Java Reference
In-Depth Information
Avail
Start
Avail
Not Avail
A
Not Avail
Not Avail
v = 9
y = v+w
Not Avail
Not Avail
v = 8
w = 5
Not Avail
Not Avail
Avail
x = v+w
Avail
Avail
Avail
Avail
z = v+w
Avail
Avail
Avail
Avail
Not Avail
v = 2
Stop
Figure 14.42: Solution throughout the flow graph of Figure 14.41(b) for
the availability of expression v + w .
In Figure 14.41(b), the shaded nodes make v + wun available. The nodes with
dark circles make v + w available. When two solutions are present at the input
of a node, we summarize them by assuming the worst case. For example, the
input to node A contains an implicit computation of v + w . However, on the
loop edge into node A, v + w is not available, because the node sponsoring that
edge changes the value of v . We must therefore assume that the current value
of v + w is not available on entry to node A.
Based on the above reasoning, information can be pushed through the
graph to reach the solution shown on each edge of Figure 14.42. The Entry
and Exit nodes have been replaced by Start and Stop nodes to indicate the
direction of data flow propagation. In the solution shown in Figure 14.42,
v + w is available on the edge entering the node that represents Marker 83
 
Search WWH ::




Custom Search