Facilitates the conveyance of CLEnv
arguments.
More...
#include <CLUtils.hpp>
Public Member Functions | |
CLEnvInfo (unsigned int _pIdx=0, unsigned int _dIdx=0, unsigned int _ctxIdx=0, const std::vector< unsigned int > _qIdx={0}, unsigned int _pgIdx=0) | |
Initializes a CLEnvInfo object. More... | |
CLEnvInfo< 1 > | getCLEnvInfo (unsigned int idx) |
Creates a new CLEnvInfo object with the specified command queue. More... | |
Public Attributes | |
unsigned int | pIdx |
unsigned int | dIdx |
unsigned int | ctxIdx |
std::vector< unsigned int > | qIdx |
unsigned int | pgIdx |
Facilitates the conveyance of CLEnv
arguments.
CLEnv
creates an OpenCL environment. A CLEnv
object potentially contains many platforms, contexts, queues, etc, that are to be used by different (independent) subsystems. Those subsystems will have to know where to look inside CLEnv for their associated CL objects. CLEnvInfo
organizes this process of information transfer between OpenCL systems.
nQueues | the number of command queue indices to be held by CLEnvInfo . |
|
inline |
Initializes a CLEnvInfo
object.
All provided indices are supposed to follow the order the associated objects were created in the associated CLEnv
instance.
[in] | _pIdx | platform index. |
[in] | _dIdx | device index. |
[in] | _ctxIdx | context index. |
[in] | _qIdx | vector with command queue indices. |
[in] | _pgIdx | program index. |
|
inline |
Creates a new CLEnvInfo
object with the specified command queue.
Maintains the same OpenCL configuration, but chooses only one of the available command queues to include.
[in] | idx | an index for the qIdx vector. |
unsigned int clutils::CLEnvInfo< nQueues >::ctxIdx |
Context index.
unsigned int clutils::CLEnvInfo< nQueues >::dIdx |
Device index.
unsigned int clutils::CLEnvInfo< nQueues >::pgIdx |
Program index.
unsigned int clutils::CLEnvInfo< nQueues >::pIdx |
Platform index.
std::vector<unsigned int> clutils::CLEnvInfo< nQueues >::qIdx |
Vector of queue indices.