Compute Library
 21.08
Kernel Class Referencefinal

Kernel class. More...

#include <CLCompileContext.h>

Public Member Functions

 Kernel ()
 Default Constructor. More...
 
 Kernel (const Kernel &)=default
 Default Copy Constructor. More...
 
 Kernel (Kernel &&)=default
 Default Move Constructor. More...
 
Kerneloperator= (const Kernel &)=default
 Default copy assignment operator. More...
 
Kerneloperator= (Kernel &&)=default
 Default move assignment operator. More...
 
 Kernel (std::string name, const cl::Program &program)
 Constructor. More...
 
std::string name () const
 Returns kernel name. More...
 
 operator cl::Kernel () const
 Returns OpenCL kernel. More...
 

Detailed Description

Kernel class.

Definition at line 160 of file CLCompileContext.h.

Constructor & Destructor Documentation

◆ Kernel() [1/4]

Kernel ( )

Default Constructor.

Definition at line 131 of file CLCompileContext.cpp.

132  : _name(), _kernel()
133 {
134 }

◆ Kernel() [2/4]

Kernel ( const Kernel )
default

Default Copy Constructor.

◆ Kernel() [3/4]

Kernel ( Kernel &&  )
default

Default Move Constructor.

◆ Kernel() [4/4]

Kernel ( std::string  name,
const cl::Program &  program 
)

Constructor.

Parameters
[in]nameKernel name.
[in]programBuilt program.

Definition at line 136 of file CLCompileContext.cpp.

137  : _name(std::move(name)),
138  _kernel(cl::Kernel(program, _name.c_str()))
139 {
140 }
std::string name() const
Returns kernel name.

Member Function Documentation

◆ name()

std::string name ( ) const
inline

Returns kernel name.

Returns
Kernel's name.

Definition at line 183 of file CLCompileContext.h.

184  {
185  return _name;
186  }

◆ operator cl::Kernel()

operator cl::Kernel ( ) const
inlineexplicit

Returns OpenCL kernel.

Returns
OpenCL Kernel.

Definition at line 191 of file CLCompileContext.h.

192  {
193  return _kernel;
194  }

◆ operator=() [1/2]

Kernel& operator= ( const Kernel )
default

Default copy assignment operator.

◆ operator=() [2/2]

Kernel& operator= ( Kernel &&  )
default

Default move assignment operator.


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