update verif
[lttv.git] / trunk / verif / examples / pan.m
CommitLineData
0b55f123 1#define rand pan_rand
2#if defined(HAS_CODE) && defined(VERBOSE)
3 cpu_printf("Pr: %d Tr: %d\n", II, t->forw);
4#endif
5 switch (t->forw) {
6 default: Uerror("bad forward move");
7 case 0: /* if without executable clauses */
8 continue;
9 case 1: /* generic 'goto' or 'skip' */
10 IfNotBlocked
11 _m = 3; goto P999;
12 case 2: /* generic 'else' */
13 IfNotBlocked
14 if (trpt->o_pm&1) continue;
15 _m = 3; goto P999;
16
17 /* PROC :init: */
2eb837fb 18 case 3: /* STATE 1 - line 226 "buffer.spin" - [i = 0] (0:0:1 - 1) */
0b55f123 19 IfNotBlocked
20 reached[4][1] = 1;
21 (trpt+1)->bup.oval = ((int)((P4 *)this)->i);
22 ((P4 *)this)->i = 0;
23#ifdef VAR_RANGES
24 logval(":init::i", ((int)((P4 *)this)->i));
25#endif
26 ;
27 _m = 3; goto P999; /* 0 */
2eb837fb 28 case 4: /* STATE 2 - line 228 "buffer.spin" - [((i<2))] (7:0:2 - 1) */
0b55f123 29 IfNotBlocked
30 reached[4][2] = 1;
31 if (!((((int)((P4 *)this)->i)<2)))
32 continue;
2eb837fb 33 /* merge: commit_count[i] = 0(7, 3, 7) */
0b55f123 34 reached[4][3] = 1;
2eb837fb 35 (trpt+1)->bup.ovals = grab_ints(2);
0b55f123 36 (trpt+1)->bup.ovals[0] = ((int)now.commit_count[ Index(((int)((P4 *)this)->i), 2) ]);
37 now.commit_count[ Index(((P4 *)this)->i, 2) ] = 0;
38#ifdef VAR_RANGES
39 logval("commit_count[:init::i]", ((int)now.commit_count[ Index(((int)((P4 *)this)->i), 2) ]));
40#endif
41 ;
2eb837fb 42 /* merge: i = (i+1)(7, 4, 7) */
0b55f123 43 reached[4][4] = 1;
2eb837fb 44 (trpt+1)->bup.ovals[1] = ((int)((P4 *)this)->i);
0b55f123 45 ((P4 *)this)->i = (((int)((P4 *)this)->i)+1);
46#ifdef VAR_RANGES
47 logval(":init::i", ((int)((P4 *)this)->i));
48#endif
49 ;
2eb837fb 50 /* merge: .(goto)(0, 8, 7) */
51 reached[4][8] = 1;
0b55f123 52 ;
2eb837fb 53 _m = 3; goto P999; /* 3 */
54 case 5: /* STATE 5 - line 231 "buffer.spin" - [((i>=2))] (16:0:2 - 1) */
0b55f123 55 IfNotBlocked
2eb837fb 56 reached[4][5] = 1;
0b55f123 57 if (!((((int)((P4 *)this)->i)>=2)))
58 continue;
59 /* dead 1: i */ (trpt+1)->bup.ovals = grab_ints(2);
60 (trpt+1)->bup.ovals[0] = ((P4 *)this)->i;
61#ifdef HAS_CODE
62 if (!readtrail)
63#endif
64 ((P4 *)this)->i = 0;
2eb837fb 65 /* merge: goto :b6(16, 6, 16) */
66 reached[4][6] = 1;
0b55f123 67 ;
2eb837fb 68 /* merge: i = 0(16, 10, 16) */
69 reached[4][10] = 1;
0b55f123 70 (trpt+1)->bup.ovals[1] = ((int)((P4 *)this)->i);
71 ((P4 *)this)->i = 0;
72#ifdef VAR_RANGES
73 logval(":init::i", ((int)((P4 *)this)->i));
74#endif
75 ;
2eb837fb 76 /* merge: .(goto)(0, 17, 16) */
77 reached[4][17] = 1;
0b55f123 78 ;
79 _m = 3; goto P999; /* 3 */
2eb837fb 80 case 6: /* STATE 10 - line 233 "buffer.spin" - [i = 0] (0:16:1 - 3) */
0b55f123 81 IfNotBlocked
2eb837fb 82 reached[4][10] = 1;
0b55f123 83 (trpt+1)->bup.oval = ((int)((P4 *)this)->i);
84 ((P4 *)this)->i = 0;
85#ifdef VAR_RANGES
86 logval(":init::i", ((int)((P4 *)this)->i));
87#endif
88 ;
2eb837fb 89 /* merge: .(goto)(0, 17, 16) */
90 reached[4][17] = 1;
0b55f123 91 ;
92 _m = 3; goto P999; /* 1 */
2eb837fb 93 case 7: /* STATE 11 - line 235 "buffer.spin" - [((i<4))] (16:0:2 - 1) */
0b55f123 94 IfNotBlocked
2eb837fb 95 reached[4][11] = 1;
0b55f123 96 if (!((((int)((P4 *)this)->i)<4)))
97 continue;
2eb837fb 98 /* merge: buffer_use[i] = 0(16, 12, 16) */
99 reached[4][12] = 1;
0b55f123 100 (trpt+1)->bup.ovals = grab_ints(2);
101 (trpt+1)->bup.ovals[0] = ((int)now.buffer_use[ Index(((int)((P4 *)this)->i), 4) ]);
102 now.buffer_use[ Index(((P4 *)this)->i, 4) ] = 0;
103#ifdef VAR_RANGES
104 logval("buffer_use[:init::i]", ((int)now.buffer_use[ Index(((int)((P4 *)this)->i), 4) ]));
105#endif
106 ;
2eb837fb 107 /* merge: i = (i+1)(16, 13, 16) */
108 reached[4][13] = 1;
0b55f123 109 (trpt+1)->bup.ovals[1] = ((int)((P4 *)this)->i);
110 ((P4 *)this)->i = (((int)((P4 *)this)->i)+1);
111#ifdef VAR_RANGES
112 logval(":init::i", ((int)((P4 *)this)->i));
113#endif
114 ;
2eb837fb 115 /* merge: .(goto)(0, 17, 16) */
116 reached[4][17] = 1;
0b55f123 117 ;
118 _m = 3; goto P999; /* 3 */
2eb837fb 119 case 8: /* STATE 14 - line 238 "buffer.spin" - [((i>=4))] (0:0:1 - 1) */
0b55f123 120 IfNotBlocked
2eb837fb 121 reached[4][14] = 1;
0b55f123 122 if (!((((int)((P4 *)this)->i)>=4)))
123 continue;
124 /* dead 1: i */ (trpt+1)->bup.oval = ((P4 *)this)->i;
125#ifdef HAS_CODE
126 if (!readtrail)
127#endif
128 ((P4 *)this)->i = 0;
129 _m = 3; goto P999; /* 0 */
2eb837fb 130 case 9: /* STATE 19 - line 240 "buffer.spin" - [(run reader())] (0:0:0 - 3) */
0b55f123 131 IfNotBlocked
2eb837fb 132 reached[4][19] = 1;
0b55f123 133 if (!(addproc(2)))
134 continue;
135 _m = 3; goto P999; /* 0 */
2eb837fb 136 case 10: /* STATE 20 - line 241 "buffer.spin" - [(run cleaner())] (28:0:1 - 1) */
0b55f123 137 IfNotBlocked
2eb837fb 138 reached[4][20] = 1;
0b55f123 139 if (!(addproc(3)))
140 continue;
2eb837fb 141 /* merge: i = 0(0, 21, 28) */
142 reached[4][21] = 1;
0b55f123 143 (trpt+1)->bup.oval = ((int)((P4 *)this)->i);
144 ((P4 *)this)->i = 0;
145#ifdef VAR_RANGES
146 logval(":init::i", ((int)((P4 *)this)->i));
147#endif
148 ;
2eb837fb 149 /* merge: .(goto)(0, 29, 28) */
150 reached[4][29] = 1;
0b55f123 151 ;
152 _m = 3; goto P999; /* 2 */
2eb837fb 153 case 11: /* STATE 22 - line 244 "buffer.spin" - [((i<4))] (24:0:1 - 1) */
0b55f123 154 IfNotBlocked
2eb837fb 155 reached[4][22] = 1;
0b55f123 156 if (!((((int)((P4 *)this)->i)<4)))
157 continue;
2eb837fb 158 /* merge: refcount = (refcount+1)(0, 23, 24) */
159 reached[4][23] = 1;
0b55f123 160 (trpt+1)->bup.oval = ((int)now.refcount);
161 now.refcount = (((int)now.refcount)+1);
162#ifdef VAR_RANGES
163 logval("refcount", ((int)now.refcount));
164#endif
165 ;
166 _m = 3; goto P999; /* 1 */
2eb837fb 167 case 12: /* STATE 24 - line 246 "buffer.spin" - [(run tracer())] (28:0:1 - 1) */
0b55f123 168 IfNotBlocked
2eb837fb 169 reached[4][24] = 1;
0b55f123 170 if (!(addproc(1)))
171 continue;
2eb837fb 172 /* merge: i = (i+1)(0, 25, 28) */
173 reached[4][25] = 1;
0b55f123 174 (trpt+1)->bup.oval = ((int)((P4 *)this)->i);
175 ((P4 *)this)->i = (((int)((P4 *)this)->i)+1);
176#ifdef VAR_RANGES
177 logval(":init::i", ((int)((P4 *)this)->i));
178#endif
179 ;
2eb837fb 180 /* merge: .(goto)(0, 29, 28) */
181 reached[4][29] = 1;
0b55f123 182 ;
183 _m = 3; goto P999; /* 2 */
2eb837fb 184 case 13: /* STATE 26 - line 248 "buffer.spin" - [((i>=4))] (38:0:2 - 1) */
0b55f123 185 IfNotBlocked
2eb837fb 186 reached[4][26] = 1;
0b55f123 187 if (!((((int)((P4 *)this)->i)>=4)))
188 continue;
189 /* dead 1: i */ (trpt+1)->bup.ovals = grab_ints(2);
190 (trpt+1)->bup.ovals[0] = ((P4 *)this)->i;
191#ifdef HAS_CODE
192 if (!readtrail)
193#endif
194 ((P4 *)this)->i = 0;
2eb837fb 195 /* merge: goto :b8(38, 27, 38) */
196 reached[4][27] = 1;
0b55f123 197 ;
2eb837fb 198 /* merge: i = 0(38, 31, 38) */
199 reached[4][31] = 1;
0b55f123 200 (trpt+1)->bup.ovals[1] = ((int)((P4 *)this)->i);
201 ((P4 *)this)->i = 0;
202#ifdef VAR_RANGES
203 logval(":init::i", ((int)((P4 *)this)->i));
204#endif
205 ;
2eb837fb 206 /* merge: .(goto)(0, 39, 38) */
207 reached[4][39] = 1;
0b55f123 208 ;
209 _m = 3; goto P999; /* 3 */
2eb837fb 210 case 14: /* STATE 31 - line 250 "buffer.spin" - [i = 0] (0:38:1 - 3) */
0b55f123 211 IfNotBlocked
2eb837fb 212 reached[4][31] = 1;
0b55f123 213 (trpt+1)->bup.oval = ((int)((P4 *)this)->i);
214 ((P4 *)this)->i = 0;
215#ifdef VAR_RANGES
216 logval(":init::i", ((int)((P4 *)this)->i));
217#endif
218 ;
2eb837fb 219 /* merge: .(goto)(0, 39, 38) */
220 reached[4][39] = 1;
0b55f123 221 ;
222 _m = 3; goto P999; /* 1 */
2eb837fb 223 case 15: /* STATE 32 - line 252 "buffer.spin" - [((i<1))] (34:0:1 - 1) */
0b55f123 224 IfNotBlocked
2eb837fb 225 reached[4][32] = 1;
0b55f123 226 if (!((((int)((P4 *)this)->i)<1)))
227 continue;
2eb837fb 228 /* merge: refcount = (refcount+1)(0, 33, 34) */
229 reached[4][33] = 1;
0b55f123 230 (trpt+1)->bup.oval = ((int)now.refcount);
231 now.refcount = (((int)now.refcount)+1);
232#ifdef VAR_RANGES
233 logval("refcount", ((int)now.refcount));
234#endif
235 ;
236 _m = 3; goto P999; /* 1 */
2eb837fb 237 case 16: /* STATE 34 - line 254 "buffer.spin" - [(run switcher())] (38:0:1 - 1) */
0b55f123 238 IfNotBlocked
2eb837fb 239 reached[4][34] = 1;
0b55f123 240 if (!(addproc(0)))
241 continue;
2eb837fb 242 /* merge: i = (i+1)(0, 35, 38) */
243 reached[4][35] = 1;
0b55f123 244 (trpt+1)->bup.oval = ((int)((P4 *)this)->i);
245 ((P4 *)this)->i = (((int)((P4 *)this)->i)+1);
246#ifdef VAR_RANGES
247 logval(":init::i", ((int)((P4 *)this)->i));
248#endif
249 ;
2eb837fb 250 /* merge: .(goto)(0, 39, 38) */
251 reached[4][39] = 1;
0b55f123 252 ;
253 _m = 3; goto P999; /* 2 */
2eb837fb 254 case 17: /* STATE 36 - line 256 "buffer.spin" - [((i>=1))] (40:0:1 - 1) */
0b55f123 255 IfNotBlocked
2eb837fb 256 reached[4][36] = 1;
0b55f123 257 if (!((((int)((P4 *)this)->i)>=1)))
258 continue;
259 /* dead 1: i */ (trpt+1)->bup.oval = ((P4 *)this)->i;
260#ifdef HAS_CODE
261 if (!readtrail)
262#endif
263 ((P4 *)this)->i = 0;
2eb837fb 264 /* merge: goto :b9(0, 37, 40) */
265 reached[4][37] = 1;
0b55f123 266 ;
267 _m = 3; goto P999; /* 1 */
2eb837fb 268 case 18: /* STATE 42 - line 262 "buffer.spin" - [assert((((write_off-read_off)>=0)&&((write_off-read_off)<(255/2))))] (0:50:2 - 1) */
0b55f123 269 IfNotBlocked
2eb837fb 270 reached[4][42] = 1;
0b55f123 271 assert((((((int)now.write_off)-((int)now.read_off))>=0)&&((((int)now.write_off)-((int)now.read_off))<(255/2))), "(((write_off-read_off)>=0)&&((write_off-read_off)<(255/2)))", II, tt, t);
2eb837fb 272 /* merge: j = 0(50, 43, 50) */
273 reached[4][43] = 1;
0b55f123 274 (trpt+1)->bup.ovals = grab_ints(2);
275 (trpt+1)->bup.ovals[0] = ((int)((P4 *)this)->j);
276 ((P4 *)this)->j = 0;
277#ifdef VAR_RANGES
278 logval(":init::j", ((int)((P4 *)this)->j));
279#endif
280 ;
2eb837fb 281 /* merge: commit_sum = 0(50, 44, 50) */
282 reached[4][44] = 1;
0b55f123 283 (trpt+1)->bup.ovals[1] = ((int)((P4 *)this)->commit_sum);
284 ((P4 *)this)->commit_sum = 0;
285#ifdef VAR_RANGES
286 logval(":init::commit_sum", ((int)((P4 *)this)->commit_sum));
287#endif
288 ;
2eb837fb 289 /* merge: .(goto)(0, 51, 50) */
290 reached[4][51] = 1;
0b55f123 291 ;
292 _m = 3; goto P999; /* 3 */
2eb837fb 293 case 19: /* STATE 45 - line 266 "buffer.spin" - [((j<2))] (50:0:2 - 1) */
0b55f123 294 IfNotBlocked
2eb837fb 295 reached[4][45] = 1;
0b55f123 296 if (!((((int)((P4 *)this)->j)<2)))
297 continue;
2eb837fb 298 /* merge: commit_sum = (commit_sum+commit_count[j])(50, 46, 50) */
299 reached[4][46] = 1;
0b55f123 300 (trpt+1)->bup.ovals = grab_ints(2);
301 (trpt+1)->bup.ovals[0] = ((int)((P4 *)this)->commit_sum);
302 ((P4 *)this)->commit_sum = (((int)((P4 *)this)->commit_sum)+((int)now.commit_count[ Index(((int)((P4 *)this)->j), 2) ]));
303#ifdef VAR_RANGES
304 logval(":init::commit_sum", ((int)((P4 *)this)->commit_sum));
305#endif
306 ;
2eb837fb 307 /* merge: j = (j+1)(50, 47, 50) */
308 reached[4][47] = 1;
0b55f123 309 (trpt+1)->bup.ovals[1] = ((int)((P4 *)this)->j);
310 ((P4 *)this)->j = (((int)((P4 *)this)->j)+1);
311#ifdef VAR_RANGES
312 logval(":init::j", ((int)((P4 *)this)->j));
313#endif
314 ;
2eb837fb 315 /* merge: .(goto)(0, 51, 50) */
316 reached[4][51] = 1;
0b55f123 317 ;
2eb837fb 318 _m = 3; goto P999; /* 3 */
319 case 20: /* STATE 48 - line 273 "buffer.spin" - [((j>=2))] (56:0:1 - 1) */
0b55f123 320 IfNotBlocked
2eb837fb 321 reached[4][48] = 1;
0b55f123 322 if (!((((int)((P4 *)this)->j)>=2)))
323 continue;
324 /* dead 1: j */ (trpt+1)->bup.oval = ((P4 *)this)->j;
325#ifdef HAS_CODE
326 if (!readtrail)
327#endif
328 ((P4 *)this)->j = 0;
2eb837fb 329 /* merge: goto :b10(56, 49, 56) */
330 reached[4][49] = 1;
0b55f123 331 ;
2eb837fb 332 /* merge: assert((((write_off-commit_sum)>=0)&&((write_off-commit_sum)<(255/2))))(56, 53, 56) */
333 reached[4][53] = 1;
0b55f123 334 assert((((((int)now.write_off)-((int)((P4 *)this)->commit_sum))>=0)&&((((int)now.write_off)-((int)((P4 *)this)->commit_sum))<(255/2))), "(((write_off-commit_sum)>=0)&&((write_off-commit_sum)<(255/2)))", II, tt, t);
2eb837fb 335 /* merge: assert((((4+1)>4)||(events_lost==0)))(56, 54, 56) */
336 reached[4][54] = 1;
0b55f123 337 assert((((4+1)>4)||(((int)now.events_lost)==0)), "(((4+1)>4)||(events_lost==0))", II, tt, t);
338 _m = 3; goto P999; /* 3 */
2eb837fb 339 case 21: /* STATE 53 - line 278 "buffer.spin" - [assert((((write_off-commit_sum)>=0)&&((write_off-commit_sum)<(255/2))))] (0:56:0 - 3) */
0b55f123 340 IfNotBlocked
2eb837fb 341 reached[4][53] = 1;
0b55f123 342 assert((((((int)now.write_off)-((int)((P4 *)this)->commit_sum))>=0)&&((((int)now.write_off)-((int)((P4 *)this)->commit_sum))<(255/2))), "(((write_off-commit_sum)>=0)&&((write_off-commit_sum)<(255/2)))", II, tt, t);
2eb837fb 343 /* merge: assert((((4+1)>4)||(events_lost==0)))(56, 54, 56) */
344 reached[4][54] = 1;
0b55f123 345 assert((((4+1)>4)||(((int)now.events_lost)==0)), "(((4+1)>4)||(events_lost==0))", II, tt, t);
346 _m = 3; goto P999; /* 1 */
2eb837fb 347 case 22: /* STATE 56 - line 284 "buffer.spin" - [-end-] (0:0:0 - 1) */
0b55f123 348 IfNotBlocked
2eb837fb 349 reached[4][56] = 1;
0b55f123 350 if (!delproc(1, II)) continue;
351 _m = 3; goto P999; /* 0 */
352
353 /* PROC cleaner */
2eb837fb 354 case 23: /* STATE 1 - line 211 "buffer.spin" - [((refcount==0))] (3:0:1 - 1) */
0b55f123 355 IfNotBlocked
356 reached[3][1] = 1;
357 if (!((((int)now.refcount)==0)))
358 continue;
359 /* merge: refcount = (refcount+1)(0, 2, 3) */
360 reached[3][2] = 1;
361 (trpt+1)->bup.oval = ((int)now.refcount);
362 now.refcount = (((int)now.refcount)+1);
363#ifdef VAR_RANGES
364 logval("refcount", ((int)now.refcount));
365#endif
366 ;
367 _m = 3; goto P999; /* 1 */
2eb837fb 368 case 24: /* STATE 3 - line 213 "buffer.spin" - [(run switcher())] (7:0:0 - 1) */
0b55f123 369 IfNotBlocked
370 reached[3][3] = 1;
371 if (!(addproc(0)))
372 continue;
373 /* merge: goto :b5(0, 4, 7) */
374 reached[3][4] = 1;
375 ;
376 _m = 3; goto P999; /* 1 */
2eb837fb 377 case 25: /* STATE 9 - line 217 "buffer.spin" - [-end-] (0:0:0 - 1) */
0b55f123 378 IfNotBlocked
379 reached[3][9] = 1;
380 if (!delproc(1, II)) continue;
381 _m = 3; goto P999; /* 0 */
382
383 /* PROC reader */
2eb837fb 384 case 26: /* STATE 1 - line 177 "buffer.spin" - [((((((write_off/(4/2))-(read_off/(4/2)))>0)&&(((write_off/(4/2))-(read_off/(4/2)))<(255/2)))&&(((commit_count[((read_off%4)/(4/2))]-(4/2))-(((read_off/4)*4)/2))==0)))] (0:0:0 - 1) */
0b55f123 385 IfNotBlocked
386 reached[2][1] = 1;
2eb837fb 387 if (!((((((((int)now.write_off)/(4/2))-(((int)now.read_off)/(4/2)))>0)&&(((((int)now.write_off)/(4/2))-(((int)now.read_off)/(4/2)))<(255/2)))&&(((((int)now.commit_count[ Index(((((int)now.read_off)%4)/(4/2)), 2) ])-(4/2))-(((((int)now.read_off)/4)*4)/2))==0))))
0b55f123 388 continue;
389 _m = 3; goto P999; /* 0 */
2eb837fb 390 case 27: /* STATE 2 - line 179 "buffer.spin" - [i = 0] (0:0:1 - 1) */
0b55f123 391 IfNotBlocked
392 reached[2][2] = 1;
393 (trpt+1)->bup.oval = ((int)((P2 *)this)->i);
394 ((P2 *)this)->i = 0;
395#ifdef VAR_RANGES
396 logval("reader:i", ((int)((P2 *)this)->i));
397#endif
398 ;
399 _m = 3; goto P999; /* 0 */
2eb837fb 400 case 28: /* STATE 3 - line 181 "buffer.spin" - [((i<(4/2)))] (9:0:2 - 1) */
0b55f123 401 IfNotBlocked
402 reached[2][3] = 1;
403 if (!((((int)((P2 *)this)->i)<(4/2))))
404 continue;
405 /* merge: assert((buffer_use[((read_off+i)%4)]==0))(9, 4, 9) */
406 reached[2][4] = 1;
407 assert((((int)now.buffer_use[ Index(((((int)now.read_off)+((int)((P2 *)this)->i))%4), 4) ])==0), "(buffer_use[((read_off+i)%4)]==0)", II, tt, t);
408 /* merge: buffer_use[((read_off+i)%4)] = 1(9, 5, 9) */
409 reached[2][5] = 1;
410 (trpt+1)->bup.ovals = grab_ints(2);
411 (trpt+1)->bup.ovals[0] = ((int)now.buffer_use[ Index(((((int)now.read_off)+((int)((P2 *)this)->i))%4), 4) ]);
412 now.buffer_use[ Index(((now.read_off+((P2 *)this)->i)%4), 4) ] = 1;
413#ifdef VAR_RANGES
414 logval("buffer_use[((read_off+reader:i)%4)]", ((int)now.buffer_use[ Index(((((int)now.read_off)+((int)((P2 *)this)->i))%4), 4) ]));
415#endif
416 ;
417 /* merge: i = (i+1)(9, 6, 9) */
418 reached[2][6] = 1;
419 (trpt+1)->bup.ovals[1] = ((int)((P2 *)this)->i);
420 ((P2 *)this)->i = (((int)((P2 *)this)->i)+1);
421#ifdef VAR_RANGES
422 logval("reader:i", ((int)((P2 *)this)->i));
423#endif
424 ;
425 /* merge: .(goto)(0, 10, 9) */
426 reached[2][10] = 1;
427 ;
428 _m = 3; goto P999; /* 4 */
2eb837fb 429 case 29: /* STATE 7 - line 185 "buffer.spin" - [((i>=(4/2)))] (11:0:1 - 1) */
0b55f123 430 IfNotBlocked
431 reached[2][7] = 1;
432 if (!((((int)((P2 *)this)->i)>=(4/2))))
433 continue;
434 /* dead 1: i */ (trpt+1)->bup.oval = ((P2 *)this)->i;
435#ifdef HAS_CODE
436 if (!readtrail)
437#endif
438 ((P2 *)this)->i = 0;
439 /* merge: goto :b3(0, 8, 11) */
440 reached[2][8] = 1;
441 ;
442 _m = 3; goto P999; /* 1 */
2eb837fb 443/* STATE 13 - line 191 "buffer.spin" - [i = 0] (0:0 - 1) same as 27 (0:0 - 1) */
444 case 30: /* STATE 14 - line 193 "buffer.spin" - [((i<(4/2)))] (19:0:2 - 1) */
0b55f123 445 IfNotBlocked
446 reached[2][14] = 1;
447 if (!((((int)((P2 *)this)->i)<(4/2))))
448 continue;
449 /* merge: buffer_use[((read_off+i)%4)] = 0(19, 15, 19) */
450 reached[2][15] = 1;
451 (trpt+1)->bup.ovals = grab_ints(2);
452 (trpt+1)->bup.ovals[0] = ((int)now.buffer_use[ Index(((((int)now.read_off)+((int)((P2 *)this)->i))%4), 4) ]);
453 now.buffer_use[ Index(((now.read_off+((P2 *)this)->i)%4), 4) ] = 0;
454#ifdef VAR_RANGES
455 logval("buffer_use[((read_off+reader:i)%4)]", ((int)now.buffer_use[ Index(((((int)now.read_off)+((int)((P2 *)this)->i))%4), 4) ]));
456#endif
457 ;
458 /* merge: i = (i+1)(19, 16, 19) */
459 reached[2][16] = 1;
460 (trpt+1)->bup.ovals[1] = ((int)((P2 *)this)->i);
461 ((P2 *)this)->i = (((int)((P2 *)this)->i)+1);
462#ifdef VAR_RANGES
463 logval("reader:i", ((int)((P2 *)this)->i));
464#endif
465 ;
466 /* merge: .(goto)(0, 20, 19) */
467 reached[2][20] = 1;
468 ;
469 _m = 3; goto P999; /* 3 */
2eb837fb 470 case 31: /* STATE 17 - line 196 "buffer.spin" - [((i>=(4/2)))] (0:0:1 - 1) */
0b55f123 471 IfNotBlocked
472 reached[2][17] = 1;
473 if (!((((int)((P2 *)this)->i)>=(4/2))))
474 continue;
2eb837fb 475 /* dead 1: i */ (trpt+1)->bup.oval = ((P2 *)this)->i;
0b55f123 476#ifdef HAS_CODE
477 if (!readtrail)
478#endif
479 ((P2 *)this)->i = 0;
2eb837fb 480 _m = 3; goto P999; /* 0 */
481 case 32: /* STATE 22 - line 198 "buffer.spin" - [read_off = (read_off+(4/2))] (0:0:1 - 1) */
0b55f123 482 IfNotBlocked
483 reached[2][22] = 1;
2eb837fb 484 (trpt+1)->bup.oval = ((int)now.read_off);
0b55f123 485 now.read_off = (((int)now.read_off)+(4/2));
486#ifdef VAR_RANGES
487 logval("read_off", ((int)now.read_off));
488#endif
489 ;
2eb837fb 490 _m = 3; goto P999; /* 0 */
491 case 33: /* STATE 24 - line 200 "buffer.spin" - [((read_off>=(4-events_lost)))] (0:0:0 - 1) */
0b55f123 492 IfNotBlocked
2eb837fb 493 reached[2][24] = 1;
0b55f123 494 if (!((((int)now.read_off)>=(4-((int)now.events_lost)))))
495 continue;
496 _m = 3; goto P999; /* 0 */
2eb837fb 497 case 34: /* STATE 29 - line 202 "buffer.spin" - [-end-] (0:0:0 - 3) */
0b55f123 498 IfNotBlocked
2eb837fb 499 reached[2][29] = 1;
0b55f123 500 if (!delproc(1, II)) continue;
501 _m = 3; goto P999; /* 0 */
502
503 /* PROC tracer */
2eb837fb 504 case 35: /* STATE 1 - line 106 "buffer.spin" - [prev_off = write_off] (0:10:2 - 1) */
0b55f123 505 IfNotBlocked
506 reached[1][1] = 1;
507 (trpt+1)->bup.ovals = grab_ints(2);
508 (trpt+1)->bup.ovals[0] = ((int)((P1 *)this)->prev_off);
509 ((P1 *)this)->prev_off = ((int)now.write_off);
510#ifdef VAR_RANGES
511 logval("tracer:prev_off", ((int)((P1 *)this)->prev_off));
512#endif
513 ;
514 /* merge: new_off = (prev_off+size)(10, 2, 10) */
515 reached[1][2] = 1;
516 (trpt+1)->bup.ovals[1] = ((int)((P1 *)this)->new_off);
517 ((P1 *)this)->new_off = (((int)((P1 *)this)->prev_off)+((int)((P1 *)this)->size));
518#ifdef VAR_RANGES
519 logval("tracer:new_off", ((int)((P1 *)this)->new_off));
520#endif
521 ;
522 _m = 3; goto P999; /* 1 */
2eb837fb 523 case 36: /* STATE 4 - line 111 "buffer.spin" - [((((new_off-read_off)>4)&&((new_off-read_off)<(255/2))))] (0:0:1 - 1) */
0b55f123 524 IfNotBlocked
525 reached[1][4] = 1;
526 if (!((((((int)((P1 *)this)->new_off)-((int)now.read_off))>4)&&((((int)((P1 *)this)->new_off)-((int)now.read_off))<(255/2)))))
527 continue;
528 /* dead 1: new_off */ (trpt+1)->bup.oval = ((P1 *)this)->new_off;
529#ifdef HAS_CODE
530 if (!readtrail)
531#endif
532 ((P1 *)this)->new_off = 0;
533 _m = 3; goto P999; /* 0 */
2eb837fb 534 case 37: /* STATE 7 - line 113 "buffer.spin" - [(1)] (27:0:0 - 1) */
0b55f123 535 IfNotBlocked
536 reached[1][7] = 1;
537 if (!(1))
538 continue;
539 /* merge: .(goto)(0, 9, 27) */
540 reached[1][9] = 1;
541 ;
542 _m = 3; goto P999; /* 1 */
2eb837fb 543 case 38: /* STATE 11 - line 118 "buffer.spin" - [((prev_off!=write_off))] (3:0:1 - 1) */
0b55f123 544 IfNotBlocked
545 reached[1][11] = 1;
546 if (!((((int)((P1 *)this)->prev_off)!=((int)now.write_off))))
547 continue;
548 /* dead 1: prev_off */ (trpt+1)->bup.oval = ((P1 *)this)->prev_off;
549#ifdef HAS_CODE
550 if (!readtrail)
551#endif
552 ((P1 *)this)->prev_off = 0;
553 /* merge: goto cmpxchg_loop(0, 12, 3) */
554 reached[1][12] = 1;
555 ;
556 _m = 3; goto P999; /* 1 */
2eb837fb 557 case 39: /* STATE 14 - line 119 "buffer.spin" - [write_off = new_off] (0:24:2 - 1) */
0b55f123 558 IfNotBlocked
559 reached[1][14] = 1;
560 (trpt+1)->bup.ovals = grab_ints(2);
561 (trpt+1)->bup.ovals[0] = ((int)now.write_off);
562 now.write_off = ((int)((P1 *)this)->new_off);
563#ifdef VAR_RANGES
564 logval("write_off", ((int)now.write_off));
565#endif
566 ;
567 /* merge: .(goto)(24, 16, 24) */
568 reached[1][16] = 1;
569 ;
570 /* merge: i = 0(24, 17, 24) */
571 reached[1][17] = 1;
572 (trpt+1)->bup.ovals[1] = ((int)((P1 *)this)->i);
573 ((P1 *)this)->i = 0;
574#ifdef VAR_RANGES
575 logval("tracer:i", ((int)((P1 *)this)->i));
576#endif
577 ;
578 /* merge: .(goto)(0, 25, 24) */
579 reached[1][25] = 1;
580 ;
581 _m = 3; goto P999; /* 3 */
2eb837fb 582 case 40: /* STATE 17 - line 121 "buffer.spin" - [i = 0] (0:24:1 - 2) */
0b55f123 583 IfNotBlocked
584 reached[1][17] = 1;
585 (trpt+1)->bup.oval = ((int)((P1 *)this)->i);
586 ((P1 *)this)->i = 0;
587#ifdef VAR_RANGES
588 logval("tracer:i", ((int)((P1 *)this)->i));
589#endif
590 ;
591 /* merge: .(goto)(0, 25, 24) */
592 reached[1][25] = 1;
593 ;
594 _m = 3; goto P999; /* 1 */
2eb837fb 595 case 41: /* STATE 18 - line 123 "buffer.spin" - [((i<size))] (24:0:2 - 1) */
0b55f123 596 IfNotBlocked
597 reached[1][18] = 1;
598 if (!((((int)((P1 *)this)->i)<((int)((P1 *)this)->size))))
599 continue;
600 /* merge: assert((buffer_use[((prev_off+i)%4)]==0))(24, 19, 24) */
601 reached[1][19] = 1;
602 assert((((int)now.buffer_use[ Index(((((int)((P1 *)this)->prev_off)+((int)((P1 *)this)->i))%4), 4) ])==0), "(buffer_use[((prev_off+i)%4)]==0)", II, tt, t);
603 /* merge: buffer_use[((prev_off+i)%4)] = 1(24, 20, 24) */
604 reached[1][20] = 1;
605 (trpt+1)->bup.ovals = grab_ints(2);
606 (trpt+1)->bup.ovals[0] = ((int)now.buffer_use[ Index(((((int)((P1 *)this)->prev_off)+((int)((P1 *)this)->i))%4), 4) ]);
607 now.buffer_use[ Index(((((P1 *)this)->prev_off+((P1 *)this)->i)%4), 4) ] = 1;
608#ifdef VAR_RANGES
609 logval("buffer_use[((tracer:prev_off+tracer:i)%4)]", ((int)now.buffer_use[ Index(((((int)((P1 *)this)->prev_off)+((int)((P1 *)this)->i))%4), 4) ]));
610#endif
611 ;
612 /* merge: i = (i+1)(24, 21, 24) */
613 reached[1][21] = 1;
614 (trpt+1)->bup.ovals[1] = ((int)((P1 *)this)->i);
615 ((P1 *)this)->i = (((int)((P1 *)this)->i)+1);
616#ifdef VAR_RANGES
617 logval("tracer:i", ((int)((P1 *)this)->i));
618#endif
619 ;
620 /* merge: .(goto)(0, 25, 24) */
621 reached[1][25] = 1;
622 ;
623 _m = 3; goto P999; /* 4 */
2eb837fb 624 case 42: /* STATE 22 - line 127 "buffer.spin" - [((i>=size))] (26:0:1 - 1) */
0b55f123 625 IfNotBlocked
626 reached[1][22] = 1;
627 if (!((((int)((P1 *)this)->i)>=((int)((P1 *)this)->size))))
628 continue;
629 /* dead 1: i */ (trpt+1)->bup.oval = ((P1 *)this)->i;
630#ifdef HAS_CODE
631 if (!readtrail)
632#endif
633 ((P1 *)this)->i = 0;
634 /* merge: goto :b0(0, 23, 26) */
635 reached[1][23] = 1;
636 ;
637 _m = 3; goto P999; /* 1 */
2eb837fb 638 case 43: /* STATE 28 - line 134 "buffer.spin" - [i = 0] (0:0:1 - 1) */
0b55f123 639 IfNotBlocked
640 reached[1][28] = 1;
641 (trpt+1)->bup.oval = ((int)((P1 *)this)->i);
642 ((P1 *)this)->i = 0;
643#ifdef VAR_RANGES
644 logval("tracer:i", ((int)((P1 *)this)->i));
645#endif
646 ;
647 _m = 3; goto P999; /* 0 */
2eb837fb 648 case 44: /* STATE 29 - line 136 "buffer.spin" - [((i<size))] (34:0:2 - 1) */
0b55f123 649 IfNotBlocked
650 reached[1][29] = 1;
651 if (!((((int)((P1 *)this)->i)<((int)((P1 *)this)->size))))
652 continue;
653 /* merge: buffer_use[((prev_off+i)%4)] = 0(34, 30, 34) */
654 reached[1][30] = 1;
655 (trpt+1)->bup.ovals = grab_ints(2);
656 (trpt+1)->bup.ovals[0] = ((int)now.buffer_use[ Index(((((int)((P1 *)this)->prev_off)+((int)((P1 *)this)->i))%4), 4) ]);
657 now.buffer_use[ Index(((((P1 *)this)->prev_off+((P1 *)this)->i)%4), 4) ] = 0;
658#ifdef VAR_RANGES
659 logval("buffer_use[((tracer:prev_off+tracer:i)%4)]", ((int)now.buffer_use[ Index(((((int)((P1 *)this)->prev_off)+((int)((P1 *)this)->i))%4), 4) ]));
660#endif
661 ;
662 /* merge: i = (i+1)(34, 31, 34) */
663 reached[1][31] = 1;
664 (trpt+1)->bup.ovals[1] = ((int)((P1 *)this)->i);
665 ((P1 *)this)->i = (((int)((P1 *)this)->i)+1);
666#ifdef VAR_RANGES
667 logval("tracer:i", ((int)((P1 *)this)->i));
668#endif
669 ;
670 /* merge: .(goto)(0, 35, 34) */
671 reached[1][35] = 1;
672 ;
673 _m = 3; goto P999; /* 3 */
2eb837fb 674 case 45: /* STATE 32 - line 139 "buffer.spin" - [((i>=size))] (43:0:3 - 1) */
0b55f123 675 IfNotBlocked
676 reached[1][32] = 1;
677 if (!((((int)((P1 *)this)->i)>=((int)((P1 *)this)->size))))
678 continue;
679 /* dead 1: i */ (trpt+1)->bup.ovals = grab_ints(3);
680 (trpt+1)->bup.ovals[0] = ((P1 *)this)->i;
681#ifdef HAS_CODE
682 if (!readtrail)
683#endif
684 ((P1 *)this)->i = 0;
685 /* merge: goto :b1(43, 33, 43) */
686 reached[1][33] = 1;
687 ;
688 /* merge: tmp_commit = (commit_count[((prev_off%4)/(4/2))]+size)(43, 37, 43) */
689 reached[1][37] = 1;
690 (trpt+1)->bup.ovals[1] = ((int)((P1 *)this)->tmp_commit);
691 ((P1 *)this)->tmp_commit = (((int)now.commit_count[ Index(((((int)((P1 *)this)->prev_off)%4)/(4/2)), 2) ])+((int)((P1 *)this)->size));
692#ifdef VAR_RANGES
693 logval("tracer:tmp_commit", ((int)((P1 *)this)->tmp_commit));
694#endif
695 ;
696 /* merge: commit_count[((prev_off%4)/(4/2))] = tmp_commit(43, 38, 43) */
697 reached[1][38] = 1;
698 (trpt+1)->bup.ovals[2] = ((int)now.commit_count[ Index(((((int)((P1 *)this)->prev_off)%4)/(4/2)), 2) ]);
699 now.commit_count[ Index(((((P1 *)this)->prev_off%4)/(4/2)), 2) ] = ((int)((P1 *)this)->tmp_commit);
700#ifdef VAR_RANGES
701 logval("commit_count[((tracer:prev_off%4)/(4/2))]", ((int)now.commit_count[ Index(((((int)((P1 *)this)->prev_off)%4)/(4/2)), 2) ]));
702#endif
703 ;
704 _m = 3; goto P999; /* 3 */
2eb837fb 705 case 46: /* STATE 37 - line 141 "buffer.spin" - [tmp_commit = (commit_count[((prev_off%4)/(4/2))]+size)] (0:43:2 - 3) */
0b55f123 706 IfNotBlocked
707 reached[1][37] = 1;
708 (trpt+1)->bup.ovals = grab_ints(2);
709 (trpt+1)->bup.ovals[0] = ((int)((P1 *)this)->tmp_commit);
710 ((P1 *)this)->tmp_commit = (((int)now.commit_count[ Index(((((int)((P1 *)this)->prev_off)%4)/(4/2)), 2) ])+((int)((P1 *)this)->size));
711#ifdef VAR_RANGES
712 logval("tracer:tmp_commit", ((int)((P1 *)this)->tmp_commit));
713#endif
714 ;
715 /* merge: commit_count[((prev_off%4)/(4/2))] = tmp_commit(43, 38, 43) */
716 reached[1][38] = 1;
717 (trpt+1)->bup.ovals[1] = ((int)now.commit_count[ Index(((((int)((P1 *)this)->prev_off)%4)/(4/2)), 2) ]);
718 now.commit_count[ Index(((((P1 *)this)->prev_off%4)/(4/2)), 2) ] = ((int)((P1 *)this)->tmp_commit);
719#ifdef VAR_RANGES
720 logval("commit_count[((tracer:prev_off%4)/(4/2))]", ((int)now.commit_count[ Index(((((int)((P1 *)this)->prev_off)%4)/(4/2)), 2) ]));
721#endif
722 ;
723 _m = 3; goto P999; /* 1 */
2eb837fb 724 case 47: /* STATE 39 - line 145 "buffer.spin" - [((((((prev_off/4)*4)/2)+(4/2))-tmp_commit))] (49:0:3 - 1) */
0b55f123 725 IfNotBlocked
726 reached[1][39] = 1;
2eb837fb 727 if (!((((((((int)((P1 *)this)->prev_off)/4)*4)/2)+(4/2))-((int)((P1 *)this)->tmp_commit))))
0b55f123 728 continue;
2eb837fb 729 /* dead 1: prev_off */ (trpt+1)->bup.ovals = grab_ints(3);
730 (trpt+1)->bup.ovals[0] = ((P1 *)this)->prev_off;
731#ifdef HAS_CODE
732 if (!readtrail)
733#endif
734 ((P1 *)this)->prev_off = 0;
735 /* dead 1: tmp_commit */ (trpt+1)->bup.ovals[1] = ((P1 *)this)->tmp_commit;
0b55f123 736#ifdef HAS_CODE
737 if (!readtrail)
738#endif
739 ((P1 *)this)->tmp_commit = 0;
740 /* merge: deliver = 1(49, 40, 49) */
741 reached[1][40] = 1;
2eb837fb 742 (trpt+1)->bup.ovals[2] = ((int)deliver);
0b55f123 743 deliver = 1;
744#ifdef VAR_RANGES
745 logval("deliver", ((int)deliver));
746#endif
747 ;
748 /* merge: .(goto)(49, 44, 49) */
749 reached[1][44] = 1;
750 ;
751 _m = 3; goto P999; /* 2 */
2eb837fb 752 case 48: /* STATE 44 - line 150 "buffer.spin" - [.(goto)] (0:49:0 - 2) */
0b55f123 753 IfNotBlocked
754 reached[1][44] = 1;
755 ;
756 _m = 3; goto P999; /* 0 */
2eb837fb 757 case 49: /* STATE 42 - line 148 "buffer.spin" - [(1)] (49:0:0 - 1) */
0b55f123 758 IfNotBlocked
759 reached[1][42] = 1;
760 if (!(1))
761 continue;
762 /* merge: .(goto)(49, 44, 49) */
763 reached[1][44] = 1;
764 ;
765 _m = 3; goto P999; /* 1 */
2eb837fb 766 case 50: /* STATE 47 - line 154 "buffer.spin" - [events_lost = (events_lost+1)] (0:0:1 - 2) */
0b55f123 767 IfNotBlocked
768 reached[1][47] = 1;
769 (trpt+1)->bup.oval = ((int)now.events_lost);
770 now.events_lost = (((int)now.events_lost)+1);
771#ifdef VAR_RANGES
772 logval("events_lost", ((int)now.events_lost));
773#endif
774 ;
775 _m = 3; goto P999; /* 0 */
2eb837fb 776 case 51: /* STATE 48 - line 156 "buffer.spin" - [refcount = (refcount-1)] (0:0:1 - 2) */
0b55f123 777 IfNotBlocked
778 reached[1][48] = 1;
779 (trpt+1)->bup.oval = ((int)now.refcount);
780 now.refcount = (((int)now.refcount)-1);
781#ifdef VAR_RANGES
782 logval("refcount", ((int)now.refcount));
783#endif
784 ;
785 _m = 3; goto P999; /* 0 */
2eb837fb 786 case 52: /* STATE 50 - line 158 "buffer.spin" - [-end-] (0:0:0 - 1) */
0b55f123 787 IfNotBlocked
788 reached[1][50] = 1;
789 if (!delproc(1, II)) continue;
790 _m = 3; goto P999; /* 0 */
791
792 /* PROC switcher */
2eb837fb 793 case 53: /* STATE 1 - line 60 "buffer.spin" - [prev_off = write_off] (0:9:3 - 1) */
0b55f123 794 IfNotBlocked
795 reached[0][1] = 1;
796 (trpt+1)->bup.ovals = grab_ints(3);
797 (trpt+1)->bup.ovals[0] = ((int)((P0 *)this)->prev_off);
798 ((P0 *)this)->prev_off = ((int)now.write_off);
799#ifdef VAR_RANGES
800 logval("switcher:prev_off", ((int)((P0 *)this)->prev_off));
801#endif
802 ;
803 /* merge: size = ((4/2)-(prev_off%(4/2)))(9, 2, 9) */
804 reached[0][2] = 1;
805 (trpt+1)->bup.ovals[1] = ((int)((P0 *)this)->size);
806 ((P0 *)this)->size = ((4/2)-(((int)((P0 *)this)->prev_off)%(4/2)));
807#ifdef VAR_RANGES
808 logval("switcher:size", ((int)((P0 *)this)->size));
809#endif
810 ;
811 /* merge: new_off = (prev_off+size)(9, 3, 9) */
812 reached[0][3] = 1;
813 (trpt+1)->bup.ovals[2] = ((int)((P0 *)this)->new_off);
814 ((P0 *)this)->new_off = (((int)((P0 *)this)->prev_off)+((int)((P0 *)this)->size));
815#ifdef VAR_RANGES
816 logval("switcher:new_off", ((int)((P0 *)this)->new_off));
817#endif
818 ;
819 _m = 3; goto P999; /* 2 */
2eb837fb 820 case 54: /* STATE 4 - line 65 "buffer.spin" - [(((((new_off-read_off)>4)&&((new_off-read_off)<(255/2)))||(size==(4/2))))] (29:0:3 - 1) */
0b55f123 821 IfNotBlocked
822 reached[0][4] = 1;
823 if (!(((((((int)((P0 *)this)->new_off)-((int)now.read_off))>4)&&((((int)((P0 *)this)->new_off)-((int)now.read_off))<(255/2)))||(((int)((P0 *)this)->size)==(4/2)))))
824 continue;
825 /* dead 1: new_off */ (trpt+1)->bup.ovals = grab_ints(3);
826 (trpt+1)->bup.ovals[0] = ((P0 *)this)->new_off;
827#ifdef HAS_CODE
828 if (!readtrail)
829#endif
830 ((P0 *)this)->new_off = 0;
831 /* dead 1: size */ (trpt+1)->bup.ovals[1] = ((P0 *)this)->size;
832#ifdef HAS_CODE
833 if (!readtrail)
834#endif
835 ((P0 *)this)->size = 0;
836 /* merge: refcount = (refcount-1)(29, 5, 29) */
837 reached[0][5] = 1;
838 (trpt+1)->bup.ovals[2] = ((int)now.refcount);
839 now.refcount = (((int)now.refcount)-1);
840#ifdef VAR_RANGES
841 logval("refcount", ((int)now.refcount));
842#endif
843 ;
844 /* merge: goto not_needed(29, 6, 29) */
845 reached[0][6] = 1;
846 ;
847 _m = 3; goto P999; /* 2 */
2eb837fb 848 case 55: /* STATE 8 - line 68 "buffer.spin" - [(1)] (18:0:0 - 1) */
0b55f123 849 IfNotBlocked
850 reached[0][8] = 1;
851 if (!(1))
852 continue;
853 /* merge: .(goto)(0, 10, 18) */
854 reached[0][10] = 1;
855 ;
856 _m = 3; goto P999; /* 1 */
2eb837fb 857 case 56: /* STATE 12 - line 73 "buffer.spin" - [((prev_off!=write_off))] (11:0:1 - 1) */
0b55f123 858 IfNotBlocked
859 reached[0][12] = 1;
860 if (!((((int)((P0 *)this)->prev_off)!=((int)now.write_off))))
861 continue;
862 /* dead 1: prev_off */ (trpt+1)->bup.oval = ((P0 *)this)->prev_off;
863#ifdef HAS_CODE
864 if (!readtrail)
865#endif
866 ((P0 *)this)->prev_off = 0;
867 /* merge: goto cmpxchg_loop(0, 13, 11) */
868 reached[0][13] = 1;
869 ;
870 _m = 3; goto P999; /* 1 */
2eb837fb 871 case 57: /* STATE 17 - line 76 "buffer.spin" - [.(goto)] (0:28:0 - 1) */
0b55f123 872 IfNotBlocked
873 reached[0][17] = 1;
874 ;
875 _m = 3; goto P999; /* 0 */
2eb837fb 876 case 58: /* STATE 15 - line 74 "buffer.spin" - [write_off = new_off] (0:28:1 - 1) */
0b55f123 877 IfNotBlocked
878 reached[0][15] = 1;
879 (trpt+1)->bup.oval = ((int)now.write_off);
880 now.write_off = ((int)((P0 *)this)->new_off);
881#ifdef VAR_RANGES
882 logval("write_off", ((int)now.write_off));
883#endif
884 ;
885 /* merge: .(goto)(28, 17, 28) */
886 reached[0][17] = 1;
887 ;
888 _m = 3; goto P999; /* 1 */
2eb837fb 889 case 59: /* STATE 19 - line 79 "buffer.spin" - [tmp_commit = (commit_count[((prev_off%4)/(4/2))]+size)] (0:25:2 - 1) */
0b55f123 890 IfNotBlocked
891 reached[0][19] = 1;
892 (trpt+1)->bup.ovals = grab_ints(2);
893 (trpt+1)->bup.ovals[0] = ((int)((P0 *)this)->tmp_commit);
894 ((P0 *)this)->tmp_commit = (((int)now.commit_count[ Index(((((int)((P0 *)this)->prev_off)%4)/(4/2)), 2) ])+((int)((P0 *)this)->size));
895#ifdef VAR_RANGES
896 logval("switcher:tmp_commit", ((int)((P0 *)this)->tmp_commit));
897#endif
898 ;
899 /* merge: commit_count[((prev_off%4)/(4/2))] = tmp_commit(25, 20, 25) */
900 reached[0][20] = 1;
901 (trpt+1)->bup.ovals[1] = ((int)now.commit_count[ Index(((((int)((P0 *)this)->prev_off)%4)/(4/2)), 2) ]);
902 now.commit_count[ Index(((((P0 *)this)->prev_off%4)/(4/2)), 2) ] = ((int)((P0 *)this)->tmp_commit);
903#ifdef VAR_RANGES
904 logval("commit_count[((switcher:prev_off%4)/(4/2))]", ((int)now.commit_count[ Index(((((int)((P0 *)this)->prev_off)%4)/(4/2)), 2) ]));
905#endif
906 ;
907 _m = 3; goto P999; /* 1 */
2eb837fb 908 case 60: /* STATE 21 - line 83 "buffer.spin" - [((((((prev_off/4)*4)/2)+(4/2))-tmp_commit))] (29:0:4 - 1) */
0b55f123 909 IfNotBlocked
910 reached[0][21] = 1;
2eb837fb 911 if (!((((((((int)((P0 *)this)->prev_off)/4)*4)/2)+(4/2))-((int)((P0 *)this)->tmp_commit))))
0b55f123 912 continue;
2eb837fb 913 /* dead 1: prev_off */ (trpt+1)->bup.ovals = grab_ints(4);
914 (trpt+1)->bup.ovals[0] = ((P0 *)this)->prev_off;
915#ifdef HAS_CODE
916 if (!readtrail)
917#endif
918 ((P0 *)this)->prev_off = 0;
919 /* dead 1: tmp_commit */ (trpt+1)->bup.ovals[1] = ((P0 *)this)->tmp_commit;
0b55f123 920#ifdef HAS_CODE
921 if (!readtrail)
922#endif
923 ((P0 *)this)->tmp_commit = 0;
924 /* merge: deliver = 1(29, 22, 29) */
925 reached[0][22] = 1;
2eb837fb 926 (trpt+1)->bup.ovals[2] = ((int)deliver);
0b55f123 927 deliver = 1;
928#ifdef VAR_RANGES
929 logval("deliver", ((int)deliver));
930#endif
931 ;
932 /* merge: .(goto)(29, 26, 29) */
933 reached[0][26] = 1;
934 ;
935 /* merge: refcount = (refcount-1)(29, 27, 29) */
936 reached[0][27] = 1;
2eb837fb 937 (trpt+1)->bup.ovals[3] = ((int)now.refcount);
0b55f123 938 now.refcount = (((int)now.refcount)-1);
939#ifdef VAR_RANGES
940 logval("refcount", ((int)now.refcount));
941#endif
942 ;
943 _m = 3; goto P999; /* 3 */
2eb837fb 944 case 61: /* STATE 26 - line 88 "buffer.spin" - [.(goto)] (0:29:1 - 2) */
0b55f123 945 IfNotBlocked
946 reached[0][26] = 1;
947 ;
948 /* merge: refcount = (refcount-1)(29, 27, 29) */
949 reached[0][27] = 1;
950 (trpt+1)->bup.oval = ((int)now.refcount);
951 now.refcount = (((int)now.refcount)-1);
952#ifdef VAR_RANGES
953 logval("refcount", ((int)now.refcount));
954#endif
955 ;
956 _m = 3; goto P999; /* 1 */
2eb837fb 957 case 62: /* STATE 24 - line 86 "buffer.spin" - [(1)] (29:0:1 - 1) */
0b55f123 958 IfNotBlocked
959 reached[0][24] = 1;
960 if (!(1))
961 continue;
962 /* merge: .(goto)(29, 26, 29) */
963 reached[0][26] = 1;
964 ;
965 /* merge: refcount = (refcount-1)(29, 27, 29) */
966 reached[0][27] = 1;
967 (trpt+1)->bup.oval = ((int)now.refcount);
968 now.refcount = (((int)now.refcount)-1);
969#ifdef VAR_RANGES
970 logval("refcount", ((int)now.refcount));
971#endif
972 ;
973 _m = 3; goto P999; /* 2 */
2eb837fb 974 case 63: /* STATE 30 - line 92 "buffer.spin" - [-end-] (0:0:0 - 1) */
0b55f123 975 IfNotBlocked
976 reached[0][30] = 1;
977 if (!delproc(1, II)) continue;
978 _m = 3; goto P999; /* 0 */
979 case _T5: /* np_ */
980 if (!((!(trpt->o_pm&4) && !(trpt->tau&128))))
981 continue;
982 /* else fall through */
983 case _T2: /* true */
984 _m = 3; goto P999;
985#undef rand
986 }
987
This page took 0.063335 seconds and 4 git commands to generate.