aboutsummaryrefslogtreecommitdiff
path: root/src/thread-pool.h
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2011-03-23 17:26:36 +0100
committerThomas White <taw@physics.org>2012-02-22 15:27:21 +0100
commit38df4f64a17cd5fc37011321b1cca386cbe970ba (patch)
tree4e28832548707da964bd3875b3030a9a8364bcfb /src/thread-pool.h
parent4ff18043dc440cd7b1b2abc84c9e6b0b3e78c0a1 (diff)
Allow tuning of CPU affinities for NUMA machines
Diffstat (limited to 'src/thread-pool.h')
-rw-r--r--src/thread-pool.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/thread-pool.h b/src/thread-pool.h
index fefcef4a..04a9e19b 100644
--- a/src/thread-pool.h
+++ b/src/thread-pool.h
@@ -28,7 +28,8 @@ extern signed int get_status_label(void);
* unique and in the range 0..n_tasks. A progress bar will be shown using
* "text" and the progress through the tasks, unless "text" is NULL. */
extern void run_thread_range(int n_tasks, int n_threads, const char *text,
- void (*work)(int, void *), void *work_args);
+ void (*work)(int, void *), void *work_args,
+ int cpu_num, int cpu_groupsize, int cpu_offset);
/* get_task() will be called every time a worker is idle. It returns either
@@ -41,7 +42,8 @@ extern void run_thread_range(int n_tasks, int n_threads, const char *text,
* Returns: the number of tasks processed. */
extern int run_threads(int n_threads, void (*work)(void *, int),
void *(*get_task)(void *), void (*final)(void *, void *),
- void *queue_args, int max);
+ void *queue_args, int max,
+ int cpu_num, int cpu_groupsize, int cpu_offset);
#endif /* THREAD_POOL_H */