aboutsummaryrefslogtreecommitdiff
path: root/libffwd/threadpool.h
diff options
context:
space:
mode:
authorOnur Gündüz <ogunduz@gmail.com>2026-06-27 00:58:05 +0200
committerOnur Gündüz <ogunduz@gmail.com>2026-06-27 01:03:41 +0200
commitaf55803d0dff9eb692c760c8d486e736c945061d (patch)
tree0875a1112bf98304e445e0544c4309670d6f4769 /libffwd/threadpool.h
parent0f861b7f3098750ddee4f6570f3be228d1da5320 (diff)
downloadffwd-af55803d0dff9eb692c760c8d486e736c945061d.tar.gz
ffwd-af55803d0dff9eb692c760c8d486e736c945061d.zip
chore: clean up comment formatting and wording
Diffstat (limited to 'libffwd/threadpool.h')
-rw-r--r--libffwd/threadpool.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/libffwd/threadpool.h b/libffwd/threadpool.h
index 1dcc80a..f9739a1 100644
--- a/libffwd/threadpool.h
+++ b/libffwd/threadpool.h
@@ -1,12 +1,14 @@
#ifndef TP_THREADPOOL_H
#define TP_THREADPOOL_H
-/* Persistent worker pool for the CPU math kernels: a fixed set of threads that
- * sleep until parallel_for() hands them a callback, plus the CPU-count helper
- * that sizes the pool (cgroup-quota aware). Separated from the math so the
- * kernels depend only on the parallel_for / tp_num_threads interface, not on
- * the pool's internals. kernels.h includes this, so kernel callers need no
- * extra include. */
+/* Persistent worker pool for CPU kernels.
+ * Uses a fixed thread set that sleeps until parallel_for() gives it a callback.
+ * Also provides the cgroup-quota-aware CPU-count helper used to size the pool.
+ *
+ * Kept separate from the kernels so they depend only on parallel_for and
+ * tp_num_threads, not pool internals.
+ *
+ * kernels.h includes this, so kernel callers need no extra include. */
/* Worker callback: (thread index, total threads, user arg). */
typedef void (*parallel_fn_t)(int tid, int n_threads, void *arg);