libresman
view src/threadpool.h @ 5:bd9b4ff19c93
more stuff
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Sat, 01 Feb 2014 08:02:08 +0200 |
parents | |
children | 410c19c735b2 |
line source
1 #ifndef THREAD_POOL_H_
2 #define THREAD_POOL_H_
4 struct thread_pool;
6 typedef void (*tpool_work_func)(void*);
8 #define TPOOL_AUTO 0
9 int tpool_init(struct thread_pool *tpool, int num_threads);
10 void tpool_destroy(struct thread_pool *tpool);
12 void tpool_set_work_func(struct thread_pool *tpool, tpool_work_func func, void *cls);
14 /* TODO cont. */
16 #endif /* THREAD_POOL_H_ */