Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/blenlib/intern/task_pool.cc')
-rw-r--r--source/blender/blenlib/intern/task_pool.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/task_pool.cc b/source/blender/blenlib/intern/task_pool.cc
index 4b545c5647e..10f15f8749c 100644
--- a/source/blender/blenlib/intern/task_pool.cc
+++ b/source/blender/blenlib/intern/task_pool.cc
@@ -131,6 +131,12 @@ class TBBTaskGroup : public tbb::task_group {
public:
TBBTaskGroup(TaskPriority priority)
{
+# if TBB_INTERFACE_VERSION_MAJOR >= 12
+ /* TODO: support priorities in TBB 2021, where they are only available as
+ * part of task arenas, no longer for task groups. Or remove support for
+ * task priorities if they are no longer useful. */
+ UNUSED_VARS(priority);
+# else
switch (priority) {
case TASK_PRIORITY_LOW:
my_context.set_priority(tbb::priority_low);
@@ -139,6 +145,7 @@ class TBBTaskGroup : public tbb::task_group {
my_context.set_priority(tbb::priority_normal);
break;
}
+# endif
}
~TBBTaskGroup()