Changeset 32cab5b for src/libcfa/concurrency/coroutine.c
- Timestamp:
- Apr 17, 2018, 12:01:09 PM (7 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, with_gc
- Children:
- 3265399
- Parents:
- b2fe1c9 (diff), 81bb114 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/libcfa/concurrency/coroutine.c
rb2fe1c9 r32cab5b 10 10 // Created On : Mon Nov 28 12:27:26 2016 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Thu Feb 8 16:10:31201813 // Update Count : 412 // Last Modified On : Fri Mar 30 17:20:57 2018 13 // Update Count : 9 14 14 // 15 15 … … 99 99 // Wrapper for co 100 100 void CoroutineCtxSwitch(coroutine_desc* src, coroutine_desc* dst) { 101 verify( preemption_state.enabled || this_processor->do_terminate );101 verify( TL_GET( preemption_state ).enabled || TL_GET( this_processor )->do_terminate ); 102 102 disable_interrupts(); 103 103 … … 106 106 107 107 // set new coroutine that task is executing 108 this_coroutine = dst;108 TL_SET( this_coroutine, dst ); 109 109 110 110 // context switch to specified coroutine … … 117 117 118 118 enable_interrupts( __cfaabi_dbg_ctx ); 119 verify( preemption_state.enabled || this_processor->do_terminate );119 verify( TL_GET( preemption_state ).enabled || TL_GET( this_processor )->do_terminate ); 120 120 } //ctxSwitchDirect 121 121 … … 172 172 173 173 void __leave_coroutine(void) { 174 coroutine_desc * src = this_coroutine;// optimization174 coroutine_desc * src = TL_GET( this_coroutine ); // optimization 175 175 176 176 assertf( src->starter != 0,
Note:
See TracChangeset
for help on using the changeset viewer.