Bolt  1.1
C++ template library with support for OpenCL
Classes | Macros
clcode.h File Reference

Defines macros to help the user create code with C++ semantics for OpenCL kernels. More...

#include <string>

Go to the source code of this file.

Classes

struct  TypeName< TypeNameType >
 
struct  ClCode< Type >
 The definition of a type trait for the definition of a type, which could be arbitrarily complex. More...
 

Macros

#define BOLT_CL_CLCODE_H
 
#define STRINGIFY_CODE2(...)   #__VA_ARGS__
 Macro that wraps around arbitrary text, and creates a string out of it This macro is helpful to write inline OpenCL programs, as it avoids wrapping every line of OpenCL line with "XXX"
.
 
#define STRINGIFY_CODE(...)   STRINGIFY_CODE2( __VA_ARGS__ )
 
#define BOLT_CODE_STRING(...)   STRINGIFY_CODE( __VA_ARGS__ ); __VA_ARGS__;
 
#define BOLT_HOST_DEVICE_DEFINITION(...)   "namespace bolt { namespace cl {\n" STRINGIFY_CODE( __VA_ARGS__ ) "\n } } \n" ; __VA_ARGS__;
 
#define BOLT_CREATE_TYPENAME(Type)   template<> struct TypeName< Type > { static std::string get( ) { return #Type; } };
 
#define BOLT_CREATE_CLCODE(Type, CODE_STRING)
 
#define BOLT_TEMPLATE_REGISTER_NEW_TYPE(CONTAINER, OLDTYPE, NEWTYPE)
 This macro specializes a template with a new type using the template definition of a previously defined type This is a convenience macro to specialize a template for a new type, using the generic template definition from a previosly defined type.
 
#define BOLT_TEMPLATE_REGISTER_NEW_ITERATOR(CONTAINER, OLDTYPE, NEWTYPE)
 This macro specializes a template iterator with a new type using the template definition of a previously defined iterator type This is a convenience macro to specialize an iterator for a new type, using the generic template definition from a previosly defined iterator.
 
#define BOLT_CREATE_DEFINE(DefineName, D,...)
 
#define BOLT_FUNCTOR(T,...)
 
#define BOLT_TEMPLATE_FUNCTOR1(CONTAINER, TYPE1,...)
 
#define BOLT_TEMPLATE_FUNCTOR2(CONTAINER, TYPE1, TYPE2,...)
 
#define BOLT_TEMPLATE_FUNCTOR3(CONTAINER, TYPE1, TYPE2, TYPE3,...)
 
#define BOLT_TEMPLATE_FUNCTOR4(CONTAINER, TYPE1, TYPE2, TYPE3, TYPE4,...)
 
#define BOLT_CREATE_CODE_SNIPPET(Name,...)
 
#define BOLT_ADD_DEPENDENCY(Type, DependingType)   ClCode<Type>::addDependency(ClCode<DependingType>::get());
 

Detailed Description

Defines macros to help the user create code with C++ semantics for OpenCL kernels.