From 7fcae7ba60ebe90cb1381e773bdfe0022fab3dc4 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Wed, 1 Mar 2017 12:51:51 +0100 Subject: Task scheduler: Remove query for the pool's number of threads Not really happy of per-pool threads limit, need to find better approach to that. But at least it's possible to get rid of half of the nastyness here by removing getter which was only used in an assert statement. That piece of code was already well-tested and this code becomes obsolete in the new depsgraph and does no longer exists in blender 2.8 branch. --- source/blender/blenlib/intern/task.c | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'source/blender/blenlib/intern/task.c') diff --git a/source/blender/blenlib/intern/task.c b/source/blender/blenlib/intern/task.c index c4761e9f7ef..a65ef881afd 100644 --- a/source/blender/blenlib/intern/task.c +++ b/source/blender/blenlib/intern/task.c @@ -687,16 +687,6 @@ void BLI_task_pool_work_and_wait(TaskPool *pool) BLI_mutex_unlock(&pool->num_mutex); } -int BLI_pool_get_num_threads(TaskPool *pool) -{ - if (pool->num_threads != 0) { - return pool->num_threads; - } - else { - return BLI_task_scheduler_num_threads(pool->scheduler); - } -} - void BLI_pool_set_num_threads(TaskPool *pool, int num_threads) { /* NOTE: Don't try to modify threads while tasks are running! */ -- cgit v1.2.3