diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-10-09 17:27:04 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-10-10 18:36:12 +0300 |
commit | 6c302d6529ec5283334e5ef40d07cc46534f5020 (patch) | |
tree | f54712920f8ea8a108f456a8279433c6a1d564a3 /source/blender/blenkernel/CMakeLists.txt | |
parent | 86042b7ced948cda215f002c125c8d850887eff0 (diff) |
Sculpt: use TBB instead of BLI_task for multithreading
This solves performance issues on some computers where there is significant
threading overhead. Rather than doing the complicated work of optimizing our
own task scheduler, use TBB which appears to work well. The downside is that
we have another thread pool, but it is already there when using OpenVDB voxel
remesh.
For future releases we can switch to using TBB to replace our task scheduler
implementation entirely, and use the same thread pool for BLI_task, Cycles,
Mantaflow, etc.
Differential Revision: https://developer.blender.org/D6030
Diffstat (limited to 'source/blender/blenkernel/CMakeLists.txt')
-rw-r--r-- | source/blender/blenkernel/CMakeLists.txt | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/blenkernel/CMakeLists.txt b/source/blender/blenkernel/CMakeLists.txt index 47b44c3828a..ec4246f5dba 100644 --- a/source/blender/blenkernel/CMakeLists.txt +++ b/source/blender/blenkernel/CMakeLists.txt @@ -183,6 +183,7 @@ set(SRC intern/particle_system.c intern/pbvh.c intern/pbvh_bmesh.c + intern/pbvh_parallel.cc intern/pointcache.c intern/report.c intern/rigidbody.c @@ -637,6 +638,14 @@ if(WITH_QUADRIFLOW) add_definitions(-DWITH_QUADRIFLOW) endif() +if(WITH_TBB) + add_definitions(-DWITH_TBB) + + list(APPEND INC_SYS + ${TBB_INCLUDE_DIRS} + ) +endif() + ## Warnings as errors, this is too strict! #if(MSVC) # set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /WX") |