28 #ifndef __MRPT_PARALLELIZATION_H
29 #define __MRPT_PARALLELIZATION_H
31 #include <mrpt/config.h>
38 #include <tbb/tbb_stddef.h>
39 #if TBB_VERSION_MAJOR*100 + TBB_VERSION_MINOR >= 202
46 #define MRPT_HAS_TBB 0
57 typedef tbb::blocked_range<int> BlockedRange;
59 template<
typename Body>
static inline
60 void parallel_for(
const BlockedRange& range,
const Body& body )
65 template<
typename Iterator,
typename Body>
static inline
66 void parallel_do( Iterator first, Iterator last,
const Body& body )
71 typedef tbb::split Split;
73 template<
typename Body>
static inline
94 template<
typename Body>
static inline
101 template<
typename Iterator,
typename Body>
static inline
102 void parallel_do( Iterator first, Iterator last,
const Body& body )
104 for( ; first != last; ++first )
110 template<
typename Body>
static inline
116 #endif // MRPT_HAS_TBB