SkePU  1.2
 All Classes Namespaces Files Functions Variables Enumerations Friends Macros Groups Pages
User Functions
#define OVERLAP_DEF_FUNC(name, type1)
 
#define UNARY_FUNC(name, type1, param1, func)
 
#define UNARY_FUNC_CONSTANT(name, type1, constType, param1, const1, func)
 
#define BINARY_FUNC(name, type1, param1, param2, func)
 
#define BINARY_FUNC_CONSTANT(name, type1, constType, param1, param2, const1, func)
 
#define TERNARY_FUNC(name, type1, param1, param2, param3, func)
 
#define TERNARY_FUNC_CONSTANT(name, type1, constType, param1, param2, param3, const1, func)
 
#define OVERLAP_FUNC(name, type1, over, param1, func)
 
#define OVERLAP_FUNC_STR(name, type1, over, param1, stride, func)
 
#define OVERLAP_FUNC_2D_STR(name, type1, overX, overY, param1, stride, func)
 
#define ARRAY_FUNC(name, type1, param1, param2, func)
 
#define ARRAY_FUNC_MATR(name, type1, param1, param2, xindex, yindex, func)
 
#define ARRAY_FUNC_MATR_BLOCK_WISE(name, type1, param1, param2, p2BlockSize, func)
 
#define ARRAY_FUNC_SPARSE_MATR_BLOCK_WISE(name, type1, param1, param2, local_nnz, p1Idx, p2BlockSize, func)
 
#define ARRAY_FUNC_MATR_CONSTANT(name, type1, constType, param1, param2, const1, xindex, yindex, func)
 
#define GENERATE_FUNC(name, type1, constType, index, const1, func)
 
#define GENERATE_FUNC_MATRIX(name, type1, constType, xindex, yindex, const1, func)
 
#define OVERLAP_DEF_FUNC(name, type1)
 
#define UNARY_FUNC(name, type1, param1, func)
 
#define UNARY_FUNC_CONSTANT(name, type1, constType, param1, const1, func)
 
#define VAR_FUNC(name, inputtype, outputtype, containertype, param1, param2, func)
 
#define BINARY_FUNC(name, type1, param1, param2, func)
 
#define BINARY_FUNC_CONSTANT(name, type1, constType, param1, param2, const1, func)
 
#define TERNARY_FUNC(name, type1, param1, param2, param3, func)
 
#define TERNARY_FUNC_CONSTANT(name, type1, constType, param1, param2, param3, const1, func)
 
#define OVERLAP_FUNC(name, type1, over, param1, func)
 
#define OVERLAP_FUNC_STR(name, type1, over, param1, stride, func)
 
#define OVERLAP_FUNC_2D_STR(name, type1, overX, overY, param1, stride, func)
 
#define ARRAY_FUNC(name, type1, param1, param2, func)
 
#define ARRAY_FUNC_MATR(name, type1, param1, param2, xindex, yindex, func)
 
#define ARRAY_FUNC_SPARSE_MATR_BLOCK_WISE(name, type1, param1, param2, local_nnz, p1Idx, p2BlockSize, func)
 
#define ARRAY_FUNC_MATR_BLOCK_WISE(name, type1, param1, param2, p2BlockSize, func)
 
#define ARRAY_FUNC_MATR_CONSTANT(name, type1, constType, param1, param2, const1, xindex, yindex, func)
 
#define GENERATE_FUNC(name, type1, constType, index, const1, func)
 
#define GENERATE_FUNC_MATRIX(name, type1, constType, xindex, yindex, const1, func)
 
#define OVERLAP_DEF_FUNC(name, type1)
 
#define UNARY_FUNC(name, type1, param1, func)
 
#define UNARY_FUNC_CONSTANT(name, type1, constType, param1, const1, func)
 
#define VAR_FUNC(name, inputtype, outputtype, containertype, param1, param2, func)
 
#define BINARY_FUNC(name, type1, param1, param2, func)
 
#define BINARY_FUNC_CONSTANT(name, type1, constType, param1, param2, const1, func)
 
#define TERNARY_FUNC(name, type1, param1, param2, param3, func)
 
#define TERNARY_FUNC_CONSTANT(name, type1, constType, param1, param2, param3, const1, func)
 
#define OVERLAP_FUNC(name, type1, over, param1, func)
 
#define OVERLAP_FUNC_STR(name, type1, over, param1, stride, func)
 
#define OVERLAP_FUNC_2D_STR(name, type1, overX, overY, param1, stride, func)
 
#define ARRAY_FUNC(name, type1, param1, param2, func)
 
#define ARRAY_FUNC_MATR(name, type1, param1, param2, xindex, yindex, func)
 
#define ARRAY_FUNC_MATR_BLOCK_WISE(name, type1, param1, param2, p2BlockSize, func)
 
#define ARRAY_FUNC_SPARSE_MATR_BLOCK_WISE(name, type1, param1, param2, local_nnz, p1Idx, p2BlockSize, func)
 
#define ARRAY_FUNC_MATR_CONSTANT(name, type1, constType, param1, param2, const1, xindex, yindex, func)
 
#define GENERATE_FUNC(name, type1, constType, index, const1, func)
 
#define GENERATE_FUNC_MATRIX(name, type1, constType, xindex, yindex, const1, func)
 
#define UNARY_FUNC(name, type1, param1, func)
 
#define UNARY_FUNC_CONSTANT(name, type1, param1, const1, func)
 
#define BINARY_FUNC(name, type1, param1, param2, func)
 
#define BINARY_FUNC_CONSTANT(name, type1, param1, param2, const1, func)
 
#define TERNARY_FUNC(name, type1, param1, param2, param3, func)
 
#define TERNARY_FUNC_CONSTANT(name, type1, param1, param2, param3, const1, func)
 
#define OVERLAP_FUNC(name, type1, over, param1, func)
 
#define OVERLAP_FUNC_STR(name, type1, over, param1, stride, func)
 
#define ARRAY_FUNC(name, type1, param1, param2, func)
 
#define ARRAY_FUNC_MATR(name, type1, param1, param2, func)
 
#define ARRAY_FUNC_MATR_CONST(name, type1, param1, param2, const1, const2, func)
 
#define GENERATE_FUNC(name, type1, index, const1, func)
 
#define UNARY_FUNC(name, type1, param1, func)   UNARY_FUNC_MF(name, type1, param1, func, func, func, func)
 
#define UNARY_FUNC_MF(name, type1, param1, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define UNARY_FUNC_CONSTANT(name, type1, param1, const1, func)   UNARY_FUNC_CONSTANT_MF(name, type1, param1, const1, func, func, func, func)
 
#define UNARY_FUNC_CONSTANT_MF(name, type1, param1, const1, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define BINARY_FUNC(name, type1, param1, param2, func)   BINARY_FUNC_MF(name, type1, param1, param2, func, func, func, func)
 
#define BINARY_FUNC_MF(name, type1, param1, param2, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define BINARY_FUNC_CONSTANT(name, type1, param1, param2, const1, func)   BINARY_FUNC_CONSTANT_MF(name, type1, param1, param2, const1, func, func, func, func)
 
#define BINARY_FUNC_CONSTANT_MF(name, type1, param1, param2, const1, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define TERNARY_FUNC(name, type1, param1, param2, param3, func)   TERNARY_FUNC_MF(name, type1, param1, param2, param3, func, func, func, func)
 
#define TERNARY_FUNC_MF(name, type1, param1, param2, param3, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define TERNARY_FUNC_CONSTANT(name, type1, param1, param2, param3, const1, func)   TERNARY_FUNC_CONSTANT_MF(name, type1, param1, param2, param3, const1, func, func, func, func)
 
#define TERNARY_FUNC_CONSTANT_MF(name, type1, param1, param2, param3, const1, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define OVERLAP_FUNC(name, type1, over, param1, func)   OVERLAP_FUNC_MF(name, type1, over, param1, func, func, func, func)
 
#define OVERLAP_FUNC_MF(name, type1, over, param1, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define ARRAY_FUNC(name, type1, param1, param2, func)   ARRAY_FUNC_MF(name, type1, param1, param2, func, func, func, func)
 
#define ARRAY_FUNC_MF(name, type1, param1, param2, CPUfunc, OMPfunc, CUfunc, CLfunc)
 
#define GENERATE_FUNC(name, type1, index, const1, func)   GENERATE_FUNC_MF(name, type1, index, const1, func, func, func, func)
 
#define GENERATE_FUNC_MF(name, type1, index, const1, CPUfunc, OMPfunc, CUfunc, CLfunc)
 

Detailed Description

Macros that generate user functions that can be used togeher with the Skeletons.

Macro Definition Documentation

#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)    ARRAY_FUNC_MF(name, type1, param1, param2, func, func, func, func)

Macro defintion for Array user functions. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
funcSame function body for all backends.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY;\
}\
inline type1 CPU(type1 * param1, type1 param2)\
{\
func\
}\
};

Macro defintion for Array user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
funcFunction body.

Macro defintion for Array user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant parameter.
funcFunction body.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
name()\
{\
funcType = skepu::ARRAY;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__global " + datatype_CL + "* " + #param1 + "," + datatype_CL + " " + #param2 + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1, type1 param2)\
{\
func\
}\
__device__ type1 CU(type1 * param1, type1 param2)\
{\
func\
}\
};

Macro defintion for Array user functions. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
funcFunction body.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
std::string constype_CL;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
constype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__global " + datatype_CL + "* " + #param1 + "," + datatype_CL + " " + #param2 + ", " + constype_CL + " " + "dummy" + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1, type1 param2)\
{\
func\
}\
};

Macro defintion for Array user functions. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
funcFunction body.

Macro defintion for Array user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant parameter.
funcFunction body.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY;\
}\
type1 CPU(type1 * param1, type1 param2)\
{\
func\
}\
__device__ type1 CU(type1 * param1, type1 param2)\
{\
func\
}\
};

Macro defintion for Array user functions. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
funcFunction body.

Macro defintion for Array user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant parameter.
funcFunction body.
#define ARRAY_FUNC_MATR (   name,
  type1,
  param1,
  param2,
  xindex,
  yindex,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX;\
}\
type1 CPU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Array user functions for Matrix. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
xindexIndex of param2 on x-axis.
yindexIndex of param2 on y-axis.
funcFunction body.
#define ARRAY_FUNC_MATR (   name,
  type1,
  param1,
  param2,
  func 
)

Macro defintion for Array user functions for Matrix. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
funcFunction body.
#define ARRAY_FUNC_MATR (   name,
  type1,
  param1,
  param2,
  xindex,
  yindex,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX;\
}\
type1 CPU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
__device__ type1 CU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Array user functions for Matrix. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
xindexIndex of param2 on x-axis.
yindexIndex of param2 on y-axis.
funcFunction body.
#define ARRAY_FUNC_MATR (   name,
  type1,
  param1,
  param2,
  xindex,
  yindex,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
std::string constype_CL;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
constype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__global " + datatype_CL + "* " + #param1 + "," + datatype_CL + " " + #param2 + ",size_t " + #xindex + ",size_t " + #yindex + ", " + constype_CL + " " + "dummy" + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Array user functions for Matrix. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
xindexIndex of param2 on x-axis.
yindexIndex of param2 on y-axis.
funcFunction body.
#define ARRAY_FUNC_MATR_BLOCK_WISE (   name,
  type1,
  param1,
  param2,
  p2BlockSize,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
size_t param2BlockSize;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX_BLOCK_WISE;\
param2BlockSize = p2BlockSize;\
}\
type1 CPU(type1 * param1, type1 * param2)\
{\
func\
}\
};

Macro defintion for Block-wise Array user functions for Matrix. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can access all elements of param1 as an array in the body.
param2Name of parameter two. Can access "p2BlockSize" elements of param2 as an array in the body.
p2BlockSizeThe size of param2 block. i.e., number of elements that can be accessed from param2.
funcFunction body.
#define ARRAY_FUNC_MATR_BLOCK_WISE (   name,
  type1,
  param1,
  param2,
  p2BlockSize,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
size_t param2BlockSize;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX_BLOCK_WISE;\
param2BlockSize = p2BlockSize;\
}\
type1 CPU(type1 * param1, type1 * param2)\
{\
func\
}\
__device__ type1 CU(type1 * param1, type1 * param2)\
{\
func\
}\
};

Macro defintion for Block-wise Array user functions for Matrix. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can access all elements of param1 as an array in the body.
param2Name of parameter two. Can access "p2BlockSize" elements of param2 as an array in the body.
p2BlockSizeThe size of param2 block. i.e., number of elements that can be accessed from param2.
funcFunction body.
#define ARRAY_FUNC_MATR_BLOCK_WISE (   name,
  type1,
  param1,
  param2,
  p2BlockSize,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
size_t param2BlockSize;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
std::string constype_CL;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX_BLOCK_WISE;\
param2BlockSize = p2BlockSize;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
constype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__global " + datatype_CL + "* " + #param1 + ", __global " + datatype_CL + "* " + #param2 + ", " + datatype_CL + " " + "dummy" + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1, type1 * param2)\
{\
func\
}\
};

Macro defintion for Block-wise Array user functions for Matrix. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can access all elements of param1 as an array in the body.
param2Name of parameter two. Can access "p2BlockSize" elements of param2 as an array in the body.
p2BlockSizeThe size of param2 block. i.e., number of elements that can be accessed from param2.
funcFunction body.
#define ARRAY_FUNC_MATR_CONST (   name,
  type1,
  param1,
  param2,
  const1,
  const2,
  func 
)

Macro defintion for Array user functions for Matrix which also supports two constants. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant one which can be used in the body.
const1Name of constant two which can be used in the body.
funcFunction body.
#define ARRAY_FUNC_MATR_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  const1,
  xindex,
  yindex,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v)\
{\
const1 = _v;\
}\
name()\
{\
funcType = skepu::ARRAY_INDEX;\
const1 = CONST_TYPE();\
}\
type1 CPU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Array user functions for Matrix which also supports two contants. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant one which can be used in the body.
xindexIndex of param2 on x-axis.
yindexIndex of param2 on y-axis.
funcFunction body.
#define ARRAY_FUNC_MATR_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  const1,
  xindex,
  yindex,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v)\
{\
const1 = _v;\
}\
name()\
{\
funcType = skepu::ARRAY_INDEX;\
const1 = CONST_TYPE();\
}\
type1 CPU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
__device__ type1 CU(type1 * param1, type1 param2, size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Array user functions for Matrix which also supports two constants. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant one which can be used in the body.
xindexIndex of param2 on x-axis.
yindexIndex of param2 on y-axis.
funcFunction body.
#define ARRAY_FUNC_MATR_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  const1,
  xindex,
  yindex,
  func 
)

Macro defintion for Array user functions for Matrix with constants. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
const1Name of constant one which can be used in the body.
xindexIndex of param2 on x-axis.
yindexIndex of param2 on y-axis.
funcFunction body.
#define ARRAY_FUNC_MF (   name,
  type1,
  param1,
  param2,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::ARRAY;\
}\
type1 CPU(type1 * param1, type1 param2)\
{\
CPUfunc\
}\
type1 OMP(type1 * param1, type1 param2)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 * param1, type1 param2)\
{\
CUfunc\
}\
};

Macro defintion for Array user functions. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can be accessed as an array in the body.
param2Name of parameter two. Only one element is accessible in the body.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define ARRAY_FUNC_SPARSE_MATR_BLOCK_WISE (   name,
  type1,
  param1,
  param2,
  local_nnz,
  p1Idx,
  p2BlockSize,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
size_t param2BlockSize;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX_SPARSE_BLOCK_WISE;\
param2BlockSize = p2BlockSize;\
}\
type1 CPU(type1 * param1, type1 * param2, size_t local_nnz, size_t *p1Idx)\
{\
func\
}\
};

Macro defintion for Block-wise Array user functions for SparseMatrix. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can access all elements of param1 as an array in the body.
param2Name of parameter two. Can access "p2BlockSize" elements of param2 as an array in the body.
local_nnzThe number of non-zero elements in param2. "local_nnz<=p2BlockSize" always.
p1IdxIndex of param1 elements corresponding to non-zero elements found in param2.
p2BlockSizeThe size of param2 block. i.e., number of elements that can be accessed from param2.
funcFunction body.
#define ARRAY_FUNC_SPARSE_MATR_BLOCK_WISE (   name,
  type1,
  param1,
  param2,
  local_nnz,
  p1Idx,
  p2BlockSize,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
size_t param2BlockSize;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX_SPARSE_BLOCK_WISE;\
param2BlockSize = p2BlockSize;\
}\
type1 CPU(type1 * param1, type1 * param2, size_t local_nnz, size_t * p1Idx)\
{\
func\
}\
__device__ type1 CU(type1 * param1, type1 * param2, size_t local_nnz, size_t * p1Idx)\
{\
func\
}\
};

Macro defintion for Block-wise Array user functions for SparseMatrix. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can access all elements of param1 as an array in the body.
param2Name of parameter two. Can access "p2BlockSize" elements of param2 as an array in the body.
local_nnzThe number of non-zero elements in param2. "local_nnz<=p2BlockSize" always.
p1IdxIndex of param1 elements corresponding to non-zero elements found in param2.
p2BlockSizeThe size of param2 block. i.e., number of elements that can be accessed from param2.
funcFunction body.
#define ARRAY_FUNC_SPARSE_MATR_BLOCK_WISE (   name,
  type1,
  param1,
  param2,
  local_nnz,
  p1Idx,
  p2BlockSize,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
size_t param2BlockSize;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
std::string constype_CL;\
type1 dummy;\
type1 getConstant() {return dummy;}\
name()\
{\
funcType = skepu::ARRAY_INDEX_SPARSE_BLOCK_WISE;\
param2BlockSize = p2BlockSize;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
constype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__global " + datatype_CL + "* " + #param1 + ", __global " + datatype_CL + "* " + #param2 + ", size_t " + #local_nnz + ", __global size_t * " + #p1Idx + ", " + constype_CL + " " + "dummy" + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1, type1 * param2, size_t local_nnz, size_t * p1Idx)\
{\
func\
}\
};

Macro defintion for Block-wise Array user functions for SparseMatrix. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the MapArray skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one. Can access all elements of param1 as an array in the body.
param2Name of parameter two. Can access "p2BlockSize" elements of param2 as an array in the body.
local_nnzThe number of non-zero elements in param2. "local_nnz<=p2BlockSize" always.
p1IdxIndex of param1 elements corresponding to non-zero elements found in param2.
p2BlockSizeThe size of param2 block. i.e., number of elements that can be accessed from param2.
funcFunction body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)    BINARY_FUNC_MF(name, type1, param1, param2, func, func, func, func)

Macro defintion for Binary user functions. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map, Reduce and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
funcSame function body for all backends.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)

Macro defintion for Binary user functions. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map, Reduce and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
funcFunction body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::BINARY;\
}\
type1 dummy;\
type1 getConstant() {return dummy;}\
inline type1 CPU(type1 param1, type1 param2)\
{\
func\
}\
type1 CPU(type1 dummy)\
{\
return dummy;\
}\
type1 CPU(type1 param1, type1 dummy, type1 dummy2)\
{\
return dummy;\
}\
};

Macro defintion for Binary user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
funcFunction body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)

Macro defintion for Binary user functions. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map, Reduce and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
funcFunction body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)

Macro defintion for Binary user functions. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map, Reduce and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
funcFunction body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  const1,
  func 
)    BINARY_FUNC_CONSTANT_MF(name, type1, param1, param2, const1, func, func, func, func)

Macro defintion for Binary user functions which also uses a constant. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
const1Name of a constant which can be used in the body.
funcSame function body for all backends.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::BINARY;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v)\
{\
const1 = _v;\
}\
type1 CPU(type1 param1, type1 param2)\
{\
func\
}\
type1 CPU(type1 dummy)\
{\
return dummy;\
}\
type1 CPU(type1 param1, type1 dummy, type1 dummy2)\
{\
return dummy;\
}\
};

Macro defintion for Binary user functions which also uses a constant. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
param2Name of parameter two.
const1Name of a constant which can be used in the body.
funcFunction body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  const1,
  func 
)

Macro defintion for Binary user functions which also uses a constant. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
const1Name of a constant which can be used in the body.
funcFunction body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  const1,
  func 
)

Macro defintion for Binary user functions which also uses a constant. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
param2Name of parameter two.
const1Name of a constant which can be used in the body.
funcFunction body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  const1,
  func 
)

Macro defintion for Binary user functions which also uses a constant. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
param2Name of parameter two.
const1Name of a constant which can be used in the body.
funcFunction body.
#define BINARY_FUNC_CONSTANT_MF (   name,
  type1,
  param1,
  param2,
  const1,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::BINARY;\
}\
type1 const1;\
type1 getConstant() {return const1;}\
void setConstant(type1 _v) {const1 = _v;}\
type1 CPU(type1 param1, type1 param2)\
{\
CPUfunc\
}\
type1 OMP(type1 param1, type1 param2)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 param1, type1 param2)\
{\
CUfunc\
}\
};

Macro defintion for Binary user functions which also uses a constant. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
const1Name of a constant which can be used in the body.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define BINARY_FUNC_MF (   name,
  type1,
  param1,
  param2,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::BINARY;\
}\
type1 dummy;\
type1 getConstant() {return dummy;}\
type1 CPU(type1 param1, type1 param2)\
{\
CPUfunc\
}\
type1 OMP(type1 param1, type1 param2)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 param1, type1 param2)\
{\
CUfunc\
}\
};

Macro defintion for Binary user functions. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map, Reduce and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define GENERATE_FUNC (   name,
  type1,
  index,
  const1,
  func 
)    GENERATE_FUNC_MF(name, type1, index, const1, func, func, func, func)

Macro defintion for Generate user functions. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
indexName of the index variable which will hold the index of the value to be generated.
const1Name of a constant which can be used in the body.
funcSame function body for all backends.
#define GENERATE_FUNC (   name,
  type1,
  constType,
  index,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::GENERATE;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v) {const1 = _v;}\
type1 CPU(size_t index)\
{\
func\
}\
};

Macro defintion for Generate user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
indexName of the index variable which will hold the index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC (   name,
  type1,
  index,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
name()\
{\
funcType = skepu::GENERATE;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(unsigned int " + #index + ", " + datatype_CL + " " + #const1 + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
type1 const1;\
type1 getConstant() {return const1;}\
void setConstant(type1 _v) {const1 = _v;}\
type1 CPU(unsigned int index)\
{\
func\
}\
__device__ type1 CU(unsigned int index)\
{\
func\
}\
};

Macro defintion for Generate user functions. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
indexName of the index variable which will hold the index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC (   name,
  type1,
  constType,
  index,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::GENERATE;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v) {const1 = _v;}\
type1 CPU(size_t index)\
{\
func\
}\
__device__ type1 CU(size_t index)\
{\
func\
}\
};

Macro defintion for Generate user functions. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
indexName of the index variable which will hold the index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC (   name,
  type1,
  constType,
  index,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
std::string constype_CL;\
name()\
{\
funcType = skepu::GENERATE;\
const1 = CONST_TYPE();\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
constype_CL.append(#constType);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(size_t " + #index + ", " + constype_CL + " " + #const1 + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v) {const1 = _v;}\
type1 CPU(size_t index)\
{\
func\
}\
};

Macro defintion for Generate user functions. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
indexName of the index variable which will hold the index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC_MATRIX (   name,
  type1,
  constType,
  xindex,
  yindex,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::GENERATE_MATRIX;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v) {const1 = _v;}\
type1 CPU(size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Generate user functions for matrix objects. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton with matrix objects.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
xindexName of the column index variable which will hold the (x-axis) column index of the value to be generated.
yindexName of the row index variable which will hold the (y-axis) row index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC_MATRIX (   name,
  type1,
  constType,
  xindex,
  yindex,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::GENERATE_MATRIX;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v) {const1 = _v;}\
type1 CPU(size_t xindex, size_t yindex)\
{\
func\
}\
__device__ type1 CU(size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Generate user functions for matrix objects. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton with matrix objects.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
xindexName of the column index variable which will hold the (x-axis) column index of the value to be generated.
yindexName of the row index variable which will hold the (y-axis) row index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC_MATRIX (   name,
  type1,
  constType,
  xindex,
  yindex,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
std::string constype_CL;\
name()\
{\
funcType = skepu::GENERATE_MATRIX;\
const1 = CONST_TYPE();\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
constype_CL.append(#constType);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(size_t " + #xindex + ", size_t " + #yindex +", " + constype_CL + " " + #const1 + ")\n"\
"{\n"\
" " #func "\n"\
"}\n");\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v) {const1 = _v;}\
type1 CPU(size_t xindex, size_t yindex)\
{\
func\
}\
};

Macro defintion for Generate user functions for matrix objects. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton with matrix objects.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
xindexName of the column index variable which will hold the (x-axis) column index of the value to be generated.
yindexName of the row index variable which will hold the (y-axis) row index of the value to be generated.
const1Name of a constant which can be used in the body.
funcFunction body.
#define GENERATE_FUNC_MF (   name,
  type1,
  index,
  const1,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::GENERATE;\
}\
type1 const1;\
type1 getConstant() {return const1;}\
void setConstant(type1 _v) {const1 = _v;}\
type1 CPU(unsigned int index)\
{\
CPUfunc\
}\
type1 OMP(unsigned int index)\
{\
OMPfunc\
}\
__device__ type1 CU(unsigned int index)\
{\
CUfunc\
}\
};

Macro defintion for Generate user functions. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used by the Generate skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
indexName of the index variable which will hold the index of the value to be generated.
const1Name of a constant which can be used in the body.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define OVERLAP_DEF_FUNC (   name,
  type1 
)
Value:
struct name\
{\
typedef type1 TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
}\
type1 CPU(type1 param1)\
{\
return param1;\
}\
};

Macro defintion for user functions that is specified when user function is not mandatory for computation. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the MapOverlap skeleton for applying 2D non-separable overlap.

Parameters
nameFunction name.
type1Type of function parameters.
#define OVERLAP_DEF_FUNC (   name,
  type1 
)
Value:
struct name\
{\
typedef type1 TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
}\
type1 CPU(type1 param1)\
{\
return param1;\
}\
__device__ type1 CU(type1 param1)\
{\
return param1;\
}\
};

Macro defintion for user functions that is specified when user function is not mandatory for computation. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the MapOverlap skeleton for applying 2D non-separable overlap.

Parameters
nameFunction name.
type1Type of function parameters.
#define OVERLAP_DEF_FUNC (   name,
  type1 
)
Value:
struct name\
{\
typedef type1 TYPE;\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
name()\
{\
funcType = skepu::OVERLAP;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__local " + datatype_CL + " *param1)\n"\
"{\n"\
" return param1[0]; \n"\
"}\n");\
}\
type1 CPU(type1 param1)\
{\
return param1;\
}\
};

Macro defintion for user functions that is specified when user function is not mandatory for computation. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the MapOverlap skeleton for applying 2D non-separable overlap.

Parameters
nameFunction name.
type1Type of function parameters.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlap;\
size_t stride;\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
overlap = over;\
stride = 1;\
}\
inline type1 CPU(type1 * param1)\
{\
func\
}\
type1 CPU_stride(type1 * param1)\
{\
func\
}\
};

Macro defintion for Overlap user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
funcFunction body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)    OVERLAP_FUNC_MF(name, type1, over, param1, func, func, func, func)

Macro defintion for Overlap user functions. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
funcSame function body for all backends.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlap;\
size_t stride;\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
name()\
{\
overlap = over;\
stride = 1;\
funcType = skepu::OVERLAP;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__local " + datatype_CL + "* " + #param1 + ")\n"\
"{\n"\
" size_t stride=1;\n " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1)\
{\
func\
}\
};

Macro defintion for Overlap user functions. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
funcFunction body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlap;\
size_t stride;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
overlap = over;\
stride = 1;\
}\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
type1 CPU(type1 * param1)\
{\
func\
}\
__device__ type1 CU(type1 * param1)\
{\
size_t stride=1;\
func\
}\
};

Macro defintion for Overlap user functions. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
funcFunction body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)

Macro defintion for Overlap user functions. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
funcFunction body.
#define OVERLAP_FUNC_2D_STR (   name,
  type1,
  overX,
  overY,
  param1,
  stride,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlapX;\
size_t overlapY;\
size_t stride;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP_2D;\
overlapX = overX;\
overlapY = overY;\
stride = 1;\
}\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
type1 CPU(type1 * param1)\
{\
func\
}\
type1 CPU(type1 * param1, size_t stride)\
{\
func\
}\
};

Macro defintion for 2D Overlap user functions with support for strided access in body. Includes a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for 2DMapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overXThe overlap length on horizontal axis used by the function.
overYThe overlap length on vertical axis used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define OVERLAP_FUNC_2D_STR (   name,
  type1,
  overX,
  overY,
  param1,
  stride,
  func 
)

Macro defintion for 2D Overlap user functions with support for strided access in body. Includes a CPU and OpenCL variant where CPU variant can also be used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for 2DMapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overXThe overlap length on horizontal axis used by the function.
overYThe overlap length on vertical axis used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define OVERLAP_FUNC_2D_STR (   name,
  type1,
  overX,
  overY,
  param1,
  stride,
  func 
)

Macro defintion for 2D Overlap user functions with support for strided access in function body. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used with 2DMapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overXThe overlap length on horizontal axis used by the function.
overYThe overlap length on vertical axis used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define OVERLAP_FUNC_MF (   name,
  type1,
  over,
  param1,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
int overlap;\
int stride;\
int getStride() {return stride;}\
void setStride(int _v) {stride = _v;}\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
overlap = over;\
stride = 1;\
}\
type1 CPU(type1 * param1)\
{\
CPUfunc\
}\
type1 OMP(type1 * param1)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 * param1)\
{\
CUfunc\
}\
};

Macro defintion for Overlap user functions. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define OVERLAP_FUNC_STR (   name,
  type1,
  over,
  param1,
  stride,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlap;\
size_t stride;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
overlap = over;\
stride = 1;\
}\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
type1 CPU(type1 * param1)\
{\
size_t stride=1;\
func\
}\
type1 CPU_stride(type1 * param1)\
{\
func\
}\
};

Macro defintion for Overlap user functions with support for strided access. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define OVERLAP_FUNC_STR (   name,
  type1,
  over,
  param1,
  stride,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlap;\
size_t stride;\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
skepu::FuncType funcType;\
std::string func_CL;\
std::string funcName_CL;\
std::string datatype_CL;\
name()\
{\
overlap = over;\
stride = 1;\
funcType = skepu::OVERLAP;\
funcName_CL.append(#name);\
datatype_CL.append(#type1);\
func_CL.append(\
datatype_CL + " " + funcName_CL + "(__local " + datatype_CL + "* " + #param1 + ")\n"\
"{\n"\
" size_t stride=1;\n " #func "\n"\
"}\n");\
}\
type1 CPU(type1 * param1)\
{\
func\
}\
};

Macro defintion for Overlap user functions that allows option for stride access. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define OVERLAP_FUNC_STR (   name,
  type1,
  over,
  param1,
  stride,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
size_t overlap;\
size_t stride;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::OVERLAP;\
overlap = over;\
stride = 1;\
}\
size_t getStride() {return stride;}\
void setStride(size_t _v) {stride = _v;}\
type1 CPU(type1 * param1)\
{\
func\
}\
__device__ type1 CU(type1 * param1)\
{\
size_t stride=1;\
func\
}\
};

Macro defintion for Overlap user functions with support for strided access in body. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define OVERLAP_FUNC_STR (   name,
  type1,
  over,
  param1,
  stride,
  func 
)

Macro defintion for Overlap user functions that allows option for stride access. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can only be used for MapOverlap skeleton.

Parameters
nameFunction name.
type1Type of function parameters.
overThe overlap length used by the function.
param1Name of parameter one.
stridethe stride which is used to access items column-wise.
funcFunction body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::TERNARY;\
}\
type1 dummy;\
type1 getConstant() {return dummy;}\
type1 CPU(type1 param1, type1 param2, type1 param3)\
{\
func\
}\
type1 CPU(type1 dummy)\
{\
return dummy;\
}\
type1 CPU(type1 param1, type1 dummy)\
{\
return dummy;\
}\
};

Macro defintion for Trinary user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
funcFunction body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)    TERNARY_FUNC_MF(name, type1, param1, param2, param3, func, func, func, func)

Macro defintion for Trinary user functions. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
funcSame function body for all backends.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)

Macro defintion for Trinary user functions. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
funcFunction body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)

Macro defintion for Trinary user functions. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
funcFunction body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)

Macro defintion for Trinary user functions. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
funcFunction body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  param3,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::TERNARY;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v)\
{\
const1 = _v;\
}\
type1 CPU(type1 param1, type1 param2, type1 param3)\
{\
func;\
}\
type1 CPU(type1 dummy)\
{\
return dummy;\
}\
type1 CPU(type1 param1, type1 dummy)\
{\
return dummy;\
}\
};

Macro defintion for Trinary user functions which also uses a constant. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
const1Name of a constant which can be used in the body.
funcFunction body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  func 
)    TERNARY_FUNC_CONSTANT_MF(name, type1, param1, param2, param3, const1, func, func, func, func)

Macro defintion for Trinary user functions which also uses a constant. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
const1Name of a constant which can be used in the body.
funcSame function body for all backends.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  param3,
  const1,
  func 
)

Macro defintion for Trinary user functions which also uses a constant. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
const1Name of a constant which can be used in the body.
funcFunction body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  func 
)

Macro defintion for Trinary user functions which also uses a constant. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
const1Name of a constant which can be used in the body.
funcFunction body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  param2,
  param3,
  const1,
  func 
)

Macro defintion for Trinary user functions which also uses a constant. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
const1Name of a constant which can be used in the body.
funcFunction body.
#define TERNARY_FUNC_CONSTANT_MF (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::TERNARY;\
}\
type1 const1;\
type1 getConstant() {return const1;}\
void setConstant(type1 _v) {const1 = _v;}\
type1 CPU(type1 param1, type1 param2, type1 param3)\
{\
CPUfunc\
}\
type1 OMP(type1 param1, type1 param2, type1 param3)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 param1, type1 param2, type1 param3)\
{\
CUfunc\
}\
};

Macro defintion for Trinary user functions which also uses a constant. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
const1Name of a constant which can be used in the body.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define TERNARY_FUNC_MF (   name,
  type1,
  param1,
  param2,
  param3,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::TERNARY;\
}\
type1 dummy;\
type1 getConstant() {return dummy;}\
type1 CPU(type1 param1, type1 param2, type1 param3)\
{\
CPUfunc\
}\
type1 OMP(type1 param1, type1 param2, type1 param3)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 param1, type1 param2, type1 param3)\
{\
CUfunc\
}\
};

Macro defintion for Trinary user functions. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
param2Name of parameter two.
param3Name of parameter three.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)

Macro defintion for Unary user functions.Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
funcFunction body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)    UNARY_FUNC_MF(name, type1, param1, func, func, func, func)

Macro defintion for Unary user functions. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
funcSame function body for all backends.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef type1 CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::UNARY;\
}\
type1 dummy;\
type1 getConstant() {return dummy;}\
type1 CPU(type1 param1)\
{\
func\
}\
type1 CPU(type1 param1, type1 dummy)\
{\
return dummy;\
}\
type1 CPU(type1 param1, type1 dummy, type1 dummy2)\
{\
return dummy;\
}\
};

Macro defintion for Unary user functions. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
funcFunction body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)

Macro defintion for Unary user functions. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
funcFunction body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)

Macro defintion for Unary user functions. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
funcFunction body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  const1,
  func 
)

Macro defintion for Unary user functions which also uses a constant. Includes an OpenCL variant (string), a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
const1Name of a constant which can be used in the body.
funcFunction body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  const1,
  func 
)    UNARY_FUNC_CONSTANT_MF(name, type1, param1, const1, func, func, func, func)

Macro defintion for Unary user functions which also uses a constant. Includes same user-function for all back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
const1Name of a constant which can be used in the body.
funcSame function body for all backends.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  const1,
  func 
)
Value:
struct name\
{\
typedef type1 TYPE;\
typedef constType CONST_TYPE;\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::UNARY;\
const1 = CONST_TYPE();\
}\
constType const1;\
constType getConstant() {return const1;}\
void setConstant(constType _v)\
{\
const1 = _v;\
}\
type1 CPU(type1 param1)\
{\
func\
}\
type1 CPU(type1 param1, type1 dummy)\
{\
return dummy;\
}\
type1 CPU(type1 param1, type1 dummy, type1 dummy2)\
{\
return dummy;\
}\
};

Macro defintion for Unary user functions which also uses a constant. Includes only a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
const1Name of a constant which can be used in the body.
funcFunction body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  const1,
  func 
)

Macro defintion for Unary user functions which also uses a constant. Includes both a CUDA variant (device function) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
const1Name of a constant which can be used in the body.
funcFunction body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  constType,
  param1,
  const1,
  func 
)

Macro defintion for Unary user functions which also uses a constant. Includes both an OpenCL variant (string) and a CPU variant also used for OpenMP. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
constTypeType of constant.
param1Name of parameter one.
const1Name of a constant which can be used in the body.
funcFunction body.
#define UNARY_FUNC_CONSTANT_MF (   name,
  type1,
  param1,
  const1,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::UNARY;\
}\
type1 const1;\
type1 getConstant() {return const1;}\
void setConstant(type1 _v) {const1 = _v;}\
type1 CPU(type1 param1)\
{\
CPUfunc\
}\
type1 OMP(type1 param1)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 param1)\
{\
CUfunc\
}\
};

Macro defintion for Unary user functions which also uses a constant. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
const1Name of a constant which can be used in the body.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define UNARY_FUNC_MF (   name,
  type1,
  param1,
  CPUfunc,
  OMPfunc,
  CUfunc,
  CLfunc 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
name()\
{\
funcType = skepu::UNARY;\
}\
type1 dummy;\
type1 getConstant() {return dummy;}\
type1 CPU(type1 param1)\
{\
CPUfunc\
}\
type1 OMP(type1 param1)\
{\
OMPfunc\
}\
__device__ type1 CU(type1 param1)\
{\
CUfunc\
}\
};

Macro defintion for Unary user functions. Includes different user-functions for different back-ends. The defintion expands as a Struct which can be used when creating new skeletons. Can be used by the Map and MapReduce skeletons.

Parameters
nameFunction name.
type1Type of function parameters.
param1Name of parameter one.
CPUfuncFunction body for CPU backend.
OMPFuncFunction body for OpenMP backend.
CUFuncFunction body for CUDA backend.
CLFuncFunction body for OpenCL backend.
#define VAR_FUNC (   name,
  inputtype,
  outputtype,
  containertype,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
bool isConst;\
name()\
{\
funcType = skepu::VAR_FUNC;\
isConst = false;\
}\
outputtype CPU(inputtype param1, containertype param2)\
{\
func\
}\
};

Macro definition for user function with variable number of inputs. Includes only a CPU variant also used for OpenMP. The definition expands as a struct which can be used when creating new skeletons. Can be used by the MapArray skeleton together with the SkePU MultiVector.

Parameters
nameFunction name.
inputtypeType of input vector
outputtypeType of output vector
containertypeThe type MultiVector should be used here
param1Name of input parameter
param2Name of MultiVector object
funcFunction body
#define VAR_FUNC (   name,
  inputtype,
  outputtype,
  containertype,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
skepu::FuncType funcType;\
bool isConst;\
name()\
{\
funcType = skepu::VAR_FUNC;\
isConst = false;\
}\
outputtype CPU(inputtype param1, containertype param2)\
{\
func\
}\
__device__ outputtype CU(inputtype param1, containertype param2)\
{\
func\
}\
};

Macro definition for user function with variable number of inputs. Includes a CUDA variant (device function) and a CPU variant also used for OpenMP. The definition expands as a struct which can be used when creating new skeletons. Can be used by the MapArray skeleton together with the SkePU MultiVector.

Parameters
nameFunction name.
inputtypeType of input vector
outputtypeType of output vector
containertypeThe type MultiVector should be used here
param1Name of input parameter
param2Name of MultiVector object
funcFunction body