Compute Library
 19.08
Kernel Class Reference

Kernel class. More...

#include <CLKernelLibrary.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 150 of file CLKernelLibrary.h.

Constructor & Destructor Documentation

◆ Kernel() [1/4]

Kernel ( )

Default Constructor.

Definition at line 133 of file CLKernelLibrary.cpp.

134  : _name(), _kernel()
135 {
136 }

◆ 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 138 of file CLKernelLibrary.cpp.

139  : _name(std::move(name)),
140  _kernel(cl::Kernel(program, _name.c_str()))
141 {
142 }
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 173 of file CLKernelLibrary.h.

174  {
175  return _name;
176  }

◆ operator cl::Kernel()

operator cl::Kernel ( ) const
inlineexplicit

Returns OpenCL kernel.

Returns
OpenCL Kernel.

Definition at line 181 of file CLKernelLibrary.h.

182  {
183  return _kernel;
184  }

◆ 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: