Changeset 5cb51502 for libcfa/src
- Timestamp:
- Apr 5, 2021, 3:18:12 PM (4 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- b0904bf
- Parents:
- c9ec301
- Location:
- libcfa/src/concurrency
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/concurrency/kernel.cfa
rc9ec301 r5cb51502 490 490 { 491 491 /* paranoid */ verify( publicTLS_get(this_proc_id) ); 492 bool full = publicTLS_get(this_proc_id)->full_proc; 493 if(full) disable_interrupts(); 492 disable_interrupts(); 494 493 495 494 /* paranoid */ verify( ! __preemption_enabled() ); … … 500 499 /* paranoid */ verify( ! __preemption_enabled() ); 501 500 502 if(full) enable_interrupts( __cfaabi_dbg_ctx);501 enable_interrupts_noPoll(); 503 502 /* paranoid */ verify( publicTLS_get(this_proc_id) ); 504 503 } … … 609 608 610 609 #if !defined(__CFA_NO_STATISTICS__) 611 __tls_stats()->ready.sleep.wakes++; 610 if( kernelTLS().this_stats ) { 611 __tls_stats()->ready.sleep.wakes++; 612 } 613 else { 614 __atomic_fetch_add(&this->stats->ready.sleep.wakes, 1, __ATOMIC_RELAXED); 615 } 612 616 #endif 613 617 -
libcfa/src/concurrency/kernel.hfa
rc9ec301 r5cb51502 51 51 struct __processor_id_t { 52 52 unsigned id:24; 53 bool full_proc:1;54 53 55 54 #if !defined(__CFA_NO_STATISTICS__) -
libcfa/src/concurrency/kernel/startup.cfa
rc9ec301 r5cb51502 455 455 this.name = name; 456 456 this.cltr = &_cltr; 457 full_proc = true;458 457 do_terminate = false; 459 458 preemption_alarm = 0p; -
libcfa/src/concurrency/ready_queue.cfa
rc9ec301 r5cb51502 245 245 __cfadbg_print_safe(ready_queue, "Kernel : Pushing %p on cluster %p\n", thrd, cltr); 246 246 247 #if !defined(__CFA_NO_STATISTICS__) 248 const bool external = (!kernelTLS().this_proc_id->full_proc) || (cltr != kernelTLS().this_processor->cltr); 249 #endif 247 const bool external = (!kernelTLS().this_processor) || (cltr != kernelTLS().this_processor->cltr); 250 248 251 249 // write timestamp … … 258 256 preferred = 259 257 //* 260 kernelTLS().this_processor ? kernelTLS().this_processor->cltr_id : -1;258 external ? -1 : kernelTLS().this_processor->cltr_id; 261 259 /*/ 262 260 thrd->link.preferred * 4;
Note: See TracChangeset
for help on using the changeset viewer.