Changes between Version 12 and Version 13 of AliasAnalysis
- Timestamp:
- 04/26/16 22:15:53 (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
AliasAnalysis
v12 v13 33 33 Note that each statement has a unique source location.\\ 34 34 Let a state `S` be a tuple `(p0: s0, p1: s1, ...)`, which contains the statement that maybe enabled for each process. \\ 35 For simplicity, the dyscope tree and the call stacks are omitted and we assume that the execution of each process is always deterministic. 35 For simplicity, the dyscope tree and the call stacks are omitted and we assume that the execution of each process is always deterministic.\\ 36 Let `AMP(S)` be the set of possible ample sets of `S`. 36 37 37 === Example 1 === 38 39 === Example 1: decides purely local statements statically === 38 40 39 41 {{{ … … 118 120 case 4: `S=(p0:s0, p1:s3)`, then `{p0, p1} \in AMP(S)`. 119 121 122 === Example 3: decides two independent transitions with thread-specific variables === 123 process-specific variables: process ID, arguments used when creating the process 124 125 {{{ 126 int x,y,z; 127 128 void f(int *q){ 129 *q = 2; // s1 130 } 131 132 int main(){ 133 int *p=&x; 134 135 $proc p1=$spawn f(&y); 136 $proc p2=$spawn f(&z); 137 138 *p=1; //s0 139 $wait(p1); 140 $wait(p2); 141 } 142 }}} 143 144 process-specific variables: `q`, let `vq` be the value of `q` when the process is created 145 146 alias analysis result: 147 148 `O(p, s0)={x}`\\ 149 `OR(p, s0)={x}` 150 151 `O(q, s1)={vq}`\\ 152 `OR(q, s1)={vq}` 153 154 let `S=(p0:s0, p1:s1, p2:s1)`, since `vq(p1)=&y`, `vq(p2)=&z`, we can conclude that `AMP(S)={{p0}, {p1}, {p2}}`, i.e., each process forms an ample set at `S`. 120 155 121 156 122 157 158 159 160 161 162
