mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-09-19 02:25:42 +00:00
Don't use patched version of TBB on newer versions.
We have a patched version of TBB's parallel_for.h in our files that fixes a problem with using std::swap. This issue has since been fixed in TBB, so for newer versions we should revert back to TBB's implementation.
This commit is contained in:
parent
91ce7b12c1
commit
ce8ecf9e8b
@ -22,7 +22,13 @@ set(headers
|
||||
ArrayManagerExecutionTBB.h
|
||||
DeviceAdapterAlgorithmTBB.h
|
||||
DeviceAdapterTagTBB.h
|
||||
parallel_sort.h
|
||||
)
|
||||
|
||||
if("${TBB_VERSION_MAJOR}.${TBB_VERSION_MINOR}" VERSION_LESS 4.3)
|
||||
if("${TBB_VERSION_MAJOR}.${TBB_VERSION_MINOR}" VERSION_LESS 4.2)
|
||||
message_error("VTK-m not tested with TBB before version 4.1. Please upgrade your TBB library.")
|
||||
endif()
|
||||
set(headers ${headers} parallel_sort.h)
|
||||
endif()
|
||||
|
||||
vtkm_declare_headers(${headers})
|
||||
|
@ -52,10 +52,15 @@ VTKM_BOOST_POST_INCLUDE
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
|
||||
#include <tbb/tbb_stddef.h>
|
||||
#if (TBB_VERSION_MAJOR == 4) && (TBB_VERSION_MINOR == 2)
|
||||
//we provide an patched implementation of tbb parallel_sort
|
||||
//that fixes ADL for std::swap. This patch has been submitted to Intel
|
||||
//and should be included in future version of TBB.
|
||||
//and is fixed in TBB 4.2 update 2.
|
||||
#include <vtkm/cont/tbb/internal/parallel_sort.h>
|
||||
#else
|
||||
#include <tbb/parallel_sort.h>
|
||||
#endif
|
||||
|
||||
#include <tbb/blocked_range.h>
|
||||
#include <tbb/blocked_range3d.h>
|
||||
|
Loading…
Reference in New Issue
Block a user