- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/concurrency/coroutine.hfa
r4269d1b r3318dff 124 124 src->state = Active; 125 125 126 if( unlikely(src->cancellation != 0p && src->cancellation != 1p) ) {126 if( unlikely(src->cancellation != 0p) ) { 127 127 __cfactx_coroutine_unwind(src->cancellation, src); 128 128 } … … 169 169 coroutine$ * dst = get_coroutine(cor); 170 170 171 // printf("FROM RES src: %p, dest: %p\n", src, dst);172 173 171 if( unlikely(dst->context.SP == 0p) ) { 174 172 __stack_prepare(&dst->stack, DEFAULT_STACK_SIZE); … … 190 188 // always done for performance testing 191 189 $ctx_switch( src, dst ); 192 193 if ( unlikely(src->cancellation == 1p) ) { 194 src->cancellation = 0p; 195 // we know dst hasn't been deallocated 190 if ( unlikely(dst->cancellation) ) { 196 191 __cfaehm_cancelled_coroutine( cor, dst, _default_vtable ); 197 192 } … … 227 222 bool poll(); 228 223 coroutine$ * resumer(); 229 coroutine$ * first_resumer();230 224 231 225 forall(T & | is_coroutine(T)) { … … 235 229 bool checked_poll( T & cor ); 236 230 coroutine$ * resumer( T & cor ); 237 coroutine$ * first_resumer( T & cor );238 231 } 239 232
Note:
See TracChangeset
for help on using the changeset viewer.