Lines Matching refs:threads_count
45 struct pthreadpool* pthreadpool_create(size_t threads_count) { in pthreadpool_create() argument
46 if (threads_count == 0) { in pthreadpool_create()
57 threads_count = (size_t) threads; in pthreadpool_create()
60 struct pthreadpool* threadpool = pthreadpool_allocate(threads_count); in pthreadpool_create()
64 threadpool->threads_count = fxdiv_init_size_t(threads_count); in pthreadpool_create()
65 for (size_t tid = 0; tid < threads_count; tid++) { in pthreadpool_create()
70 if (threads_count > 1) { in pthreadpool_create()
101 const struct fxdiv_divisor_size_t threads_count = threadpool->threads_count; in pthreadpool_parallelize() local
108 const struct fxdiv_result_size_t range_params = fxdiv_divide_size_t(linear_range, threads_count); in pthreadpool_parallelize()
110 for (size_t tid = 0; tid < threads_count.value; tid++) { in pthreadpool_parallelize()
122 dispatch_apply_f(threads_count.value, DISPATCH_APPLY_AUTO, threadpool, thread_main); in pthreadpool_parallelize()