Intel(R) Threading Building Blocks Doxygen Documentation  version 4.2.3
tbb::flow::interface10::opencl_range Class Reference

#include <flow_graph_opencl_node.h>

Collaboration diagram for tbb::flow::interface10::opencl_range:

Public Types

typedef size_t range_index_type
 
typedef std::array< range_index_type, 3 > nd_range_type
 

Public Member Functions

template<typename G = std::initializer_list<int>, typename L = std::initializer_list<int>, typename = typename std::enable_if<!std::is_same<typename std::decay<G>::type, opencl_range>::value>::type>
 opencl_range (G &&global_work=std::initializer_list< int >({ 0 }), L &&local_work=std::initializer_list< int >({ 0, 0, 0 }))
 
const nd_range_typeglobal_range () const
 
const nd_range_typelocal_range () const
 

Private Attributes

nd_range_type my_global_work_size
 
nd_range_type my_local_work_size
 

Detailed Description

Definition at line 779 of file flow_graph_opencl_node.h.

Member Typedef Documentation

◆ nd_range_type

◆ range_index_type

Constructor & Destructor Documentation

◆ opencl_range()

template<typename G = std::initializer_list<int>, typename L = std::initializer_list<int>, typename = typename std::enable_if<!std::is_same<typename std::decay<G>::type, opencl_range>::value>::type>
tbb::flow::interface10::opencl_range::opencl_range ( G &&  global_work = std::initializer_list<int>({ 0 }),
L &&  local_work = std::initializer_list<int>({ 0, 0, 0 }) 
)
inline

Definition at line 786 of file flow_graph_opencl_node.h.

786  { 0 }), L&& local_work = std::initializer_list<int>({ 0, 0, 0 })) {
787  auto g_it = global_work.begin();
788  auto l_it = local_work.begin();
789  my_global_work_size = { size_t(-1), size_t(-1), size_t(-1) };
790  // my_local_work_size is still uninitialized
791  for (int s = 0; s < 3 && g_it != global_work.end(); ++g_it, ++l_it, ++s) {
792  __TBB_ASSERT(l_it != local_work.end(), "global_work & local_work must have same size");
793  my_global_work_size[s] = *g_it;
794  my_local_work_size[s] = *l_it;
795  }
796  }
void const char const char int ITT_FORMAT __itt_group_sync s
#define __TBB_ASSERT(predicate, comment)
No-op version of __TBB_ASSERT.
Definition: tbb_stddef.h:165

Member Function Documentation

◆ global_range()

const nd_range_type& tbb::flow::interface10::opencl_range::global_range ( ) const
inline

Definition at line 798 of file flow_graph_opencl_node.h.

References my_global_work_size.

Referenced by tbb::flow::interface10::opencl_factory< default_device_filter >::send_kernel_impl().

Here is the caller graph for this function:

◆ local_range()

const nd_range_type& tbb::flow::interface10::opencl_range::local_range ( ) const
inline

Definition at line 799 of file flow_graph_opencl_node.h.

References my_local_work_size.

Referenced by tbb::flow::interface10::opencl_factory< default_device_filter >::send_kernel_impl().

Here is the caller graph for this function:

Member Data Documentation

◆ my_global_work_size

nd_range_type tbb::flow::interface10::opencl_range::my_global_work_size
private

Definition at line 802 of file flow_graph_opencl_node.h.

Referenced by global_range().

◆ my_local_work_size

nd_range_type tbb::flow::interface10::opencl_range::my_local_work_size
private

Definition at line 803 of file flow_graph_opencl_node.h.

Referenced by local_range().


The documentation for this class was generated from the following file:

Copyright © 2005-2019 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.