- Timestamp:
- Oct 19, 2023, 3:26:27 PM (10 months ago)
- Branches:
- master
- Children:
- 2d7cb19
- Parents:
- ca995e3
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tests/concurrency/waituntil/channel_close.cfa
rca995e3 rcbbfba9 26 26 for( ;; ) { 27 27 if ( useAnd ) { 28 waituntil( (in << A) ) { assert( A_removes == in ); A_removes++; removes++; }29 and waituntil( (in2 << B) ) { assert( B_removes == in2 ); B_removes++; removes++; }28 waituntil( (in << A) ) { __atomic_thread_fence( __ATOMIC_SEQ_CST ); assert( A_removes == in ); A_removes++; removes++; } 29 and waituntil( (in2 << B) ) { __atomic_thread_fence( __ATOMIC_SEQ_CST ); assert( B_removes == in2 ); B_removes++; removes++; } 30 30 continue; 31 31 } 32 waituntil( (in << A) ) { assert( A_removes == in ); A_removes++; removes++; }33 or waituntil( (in << B) ) { assert( B_removes == in ); B_removes++; removes++; }32 waituntil( (in << A) ) { __atomic_thread_fence( __ATOMIC_SEQ_CST ); assert( A_removes == in ); A_removes++; removes++; } 33 or waituntil( (in << B) ) { __atomic_thread_fence( __ATOMIC_SEQ_CST ); ( B_removes == in ); B_removes++; removes++; } 34 34 } 35 35 } catchResume ( channel_closed * e ) {} // continue to remove until would block … … 37 37 try { 38 38 for( ;; ) 39 waituntil( (in << A) ) { assert( A_removes == in ); A_removes++; removes++; }39 waituntil( (in << A) ) { __atomic_thread_fence( __ATOMIC_SEQ_CST ); assert( A_removes == in ); A_removes++; removes++; } 40 40 } catchResume ( channel_closed * e ) {} // continue to remove until would block 41 41 catch ( channel_closed * e ) {} 42 42 try { 43 43 for( ;; ) 44 waituntil( (in << B) ) { assert( B_removes == in ); B_removes++; removes++; }44 waituntil( (in << B) ) { __atomic_thread_fence( __ATOMIC_SEQ_CST ); assert( B_removes == in ); B_removes++; removes++; } 45 45 } catchResume ( channel_closed * e ) {} // continue to remove until would block 46 46 catch ( channel_closed * e ) {}
Note: See TracChangeset
for help on using the changeset viewer.