Changeset aeb31b1 for libcfa/src/concurrency
- Timestamp:
- Dec 3, 2020, 3:33:18 PM (5 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 9082e0f1, cad1df1
- Parents:
- a78c3ff (diff), 0f88a225 (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. - Location:
- libcfa/src/concurrency
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/concurrency/io.cfa
ra78c3ff raeb31b1 160 160 static inline void process(struct io_uring_cqe & cqe ) { 161 161 struct io_future_t * future = (struct io_future_t *)(uintptr_t)cqe.user_data; 162 __cfadbg_print_safe( io, "Kernel I/O : Syscall completed : cqe %p, result %d for %p\n", future, cqe.res, data->thrd);162 __cfadbg_print_safe( io, "Kernel I/O : Syscall completed : cqe %p, result %d for %p\n", &cqe, cqe.res, future ); 163 163 164 164 fulfil( *future, cqe.res ); … … 298 298 __u32 mask = *ring.submit_q.mask; 299 299 300 disable_interrupts(); 301 __u32 off = __tls_rand(); 302 enable_interrupts( __cfaabi_dbg_ctx ); 300 __u32 off = thread_rand(); 303 301 304 302 // Loop around looking for an available spot … … 344 342 __u32 ready_mask = ring.submit_q.ready_cnt - 1; 345 343 346 disable_interrupts(); 347 __u32 off = __tls_rand(); 348 enable_interrupts( __cfaabi_dbg_ctx ); 344 __u32 off = thread_rand(); 349 345 350 346 __u32 picked; -
libcfa/src/concurrency/io/call.cfa.in
ra78c3ff raeb31b1 84 84 85 85 /* paranoid */ verifyf( cltr->io.ctxs, "default io contexts for cluster %p are missing\\n", cltr); 86 return &cltr->io.ctxs[ __tls_rand() % cltr->io.cnt ];86 return &cltr->io.ctxs[ thread_rand() % cltr->io.cnt ]; 87 87 } 88 88 #endif -
libcfa/src/concurrency/kernel.cfa
ra78c3ff raeb31b1 619 619 lock( kernel_abort_lock __cfaabi_dbg_ctx2 ); 620 620 621 // disable interrupts, it no longer makes sense to try to interrupt this processor 622 disable_interrupts(); 623 621 624 // first task to abort ? 622 625 if ( kernel_abort_called ) { // not first task to abort ? -
libcfa/src/concurrency/kernel/fwd.hfa
ra78c3ff raeb31b1 132 132 } 133 133 134 extern uint64_t thread_rand(); 135 134 136 //----------------------------------------------------------------------- 135 137 // Statics call at the end of each thread to register statistics -
libcfa/src/concurrency/thread.cfa
ra78c3ff raeb31b1 162 162 } 163 163 164 uint64_t thread_rand() { 165 disable_interrupts(); 166 uint64_t ret = __tls_rand(); 167 enable_interrupts( __cfaabi_dbg_ctx ); 168 return ret; 169 } 170 164 171 // Local Variables: // 165 172 // mode: c //
Note:
See TracChangeset
for help on using the changeset viewer.