summaryrefslogtreecommitdiff
path: root/include/engine
diff options
context:
space:
mode:
Diffstat (limited to 'include/engine')
-rw-r--r--include/engine/threads.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/engine/threads.h b/include/engine/threads.h
index 43c4459..1e63a5d 100644
--- a/include/engine/threads.h
+++ b/include/engine/threads.h
@@ -56,6 +56,13 @@ struct root_thread_args {
go_args_t *go_args;
engine_message_handler_t *message;
ttable_t *ttable;
+
+ split_point_t *split_points; // shared DTS pool (§2.4)
+ size_t sp_pool_capacity;
+
+ // the root stops its workers when the search completes
+ atomic_int *workers_stop;
+ int workers_count;
};
typedef union {
@@ -87,6 +94,7 @@ void __threads_args_init(
// DTS primitives (§2.3–2.8): split point pool + lock-free move claiming
split_point_t *split_point_alloc(struct threads *handler);
+split_point_t *__pool_alloc(split_point_t *pool, size_t capacity);
void split_point_free(struct threads *handler, split_point_t *split_point);
void split_point_publish(split_point_t *split_point);
bool split_point_claim_move(split_point_t *split_point, move_t *move);