User Functions



#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 ARRAY_FUNC(name, type1, param1, param2, func)
#define GENERATE_FUNC(name, type1, index, 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 ARRAY_FUNC(name, type1, param1, param2, func)
#define GENERATE_FUNC(name, type1, index, 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 ARRAY_FUNC(name, type1, param1, param2, func)
#define GENERATE_FUNC(name, type1, index, 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 ARRAY_FUNC(name, type1, param1, param2, func)
#define GENERATE_FUNC(name, type1, index, const1, func)

Detailed Description

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


Define Documentation

#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    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\
    }\
};

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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one. Can be accessed as an array in the body.
param2 Name of parameter two. Only one element is accessible in the body.
func Function body.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::ARRAY;\
    }\
    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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one. Can be accessed as an array in the body.
param2 Name of parameter two. Only one element is accessible in the body.
func Function body.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one. Can be accessed as an array in the body.
param2 Name of parameter two. Only one element is accessible in the body.
func Function body.
#define ARRAY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one. Can be accessed as an array in the body.
param2 Name of parameter two. Only one element is accessible in the body.
func Function body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::BINARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + "dummy" + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
func Function body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::BINARY;\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
func Function body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::BINARY;\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2)\
    {\
        func\
    }\
};

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, Reduce and MapReduce skeletons.

Parameters:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
func Function body.
#define BINARY_FUNC (   name,
  type1,
  param1,
  param2,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::BINARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + "dummy" + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
func Function body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  const1,
  func 
)
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)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 param2)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
const1 Name of a constant which can be used in the body.
func Function body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  const1,
  func 
)
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)\
    {\
        func\
    }\
};

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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
const1 Name of a constant which can be used in the body.
func Function body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  const1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::BINARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + #const1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 const1;\
    type1 getConstant() {return const1;}\
    void setConstant(type1 _v) {const1 = _v;}\
    type1 CPU(type1 param1, type1 param2)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 param2)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
const1 Name of a constant which can be used in the body.
func Function body.
#define BINARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  const1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::BINARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + #const1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 const1;\
    type1 getConstant() {return const1;}\
    void setConstant(type1 _v) {const1 = _v;}\
    type1 CPU(type1 param1, type1 param2)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
const1 Name of a constant which can be used in the body.
func Function body.
#define GENERATE_FUNC (   name,
  type1,
  index,
  const1,
  func 
)
Value:
struct name\
{\
    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:
name Function name.
type1 Type of function parameters.
index Name of the index variable which will hold the index of the value to be generated.
const1 Name of a constant which can be used in the body.
func Function body.
#define GENERATE_FUNC (   name,
  type1,
  index,
  const1,
  func 
)
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)\
    {\
        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:
name Function name.
type1 Type of function parameters.
index Name of the index variable which will hold the index of the value to be generated.
const1 Name of a constant which can be used in the body.
func Function body.
#define GENERATE_FUNC (   name,
  type1,
  index,
  const1,
  func 
)
Value:
struct name\
{\
    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\
    }\
};

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:
name Function name.
type1 Type of function parameters.
index Name of the index variable which will hold the index of the value to be generated.
const1 Name of a constant which can be used in the body.
func Function body.
#define GENERATE_FUNC (   name,
  type1,
  index,
  const1,
  func 
)
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)\
    {\
        func\
    }\
    __device__ type1 CU(unsigned int 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:
name Function name.
type1 Type of function parameters.
index Name of the index variable which will hold the index of the value to be generated.
const1 Name of a constant which can be used in the body.
func Function body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
    int overlap;\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        overlap = over;\
        funcType = skepu::OVERLAP;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(__local " + datatype_CL + "* " + #param1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 CPU(type1 * param1)\
    {\
        func\
    }\
    __device__ type1 CU(type1 * 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:
name Function name.
type1 Type of function parameters.
over The overlap length used by the function.
param1 Name of parameter one.
func Function body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
    int overlap;\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::OVERLAP;\
        overlap = over;\
    }\
    type1 CPU(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:
name Function name.
type1 Type of function parameters.
over The overlap length used by the function.
param1 Name of parameter one.
func Function body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
    int overlap;\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        overlap = over;\
        funcType = skepu::OVERLAP;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(__local " + datatype_CL + "* " + #param1 + ")\n"\
        "{\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:
name Function name.
type1 Type of function parameters.
over The overlap length used by the function.
param1 Name of parameter one.
func Function body.
#define OVERLAP_FUNC (   name,
  type1,
  over,
  param1,
  func 
)
Value:
struct name\
{\
    int overlap;\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::OVERLAP;\
        overlap = over;\
    }\
    type1 CPU(type1 * param1)\
    {\
        func\
    }\
    __device__ type1 CU(type1 * param1)\
    {\
        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:
name Function name.
type1 Type of function parameters.
over The overlap length used by the function.
param1 Name of parameter one.
func Function body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::TERNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + #param3 + ", " + datatype_CL + " " + "dummy" + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2, type1 param3)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 param2, type1 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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
func Function body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::TERNARY;\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2, type1 param3)\
    {\
        func\
    }\
};

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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
func Function body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::TERNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + #param3 + ", " + datatype_CL + " " + "dummy" + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2, type1 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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
func Function body.
#define TERNARY_FUNC (   name,
  type1,
  param1,
  param2,
  param3,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::TERNARY;\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1, type1 param2, type1 param3)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 param2, type1 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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
func Function body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::TERNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + #param3 + ", " + datatype_CL + " " + #const1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 const1;\
    type1 getConstant() {return const1;}\
    void setConstant(type1 _v) {const1 = _v;}\
    type1 CPU(type1 param1, type1 param2, type1 param3)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
const1 Name of a constant which can be used in the body.
func Function body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  func 
)
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)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 param2, type1 param3)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
const1 Name of a constant which can be used in the body.
func Function body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  func 
)
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)\
    {\
        func\
    }\
};

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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
const1 Name of a constant which can be used in the body.
func Function body.
#define TERNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  param2,
  param3,
  const1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::TERNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #param2 + ", " + datatype_CL + " " + #param3 + ", " + datatype_CL + " " + #const1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 const1;\
    type1 getConstant() {return const1;}\
    void setConstant(type1 _v) {const1 = _v;}\
    type1 CPU(type1 param1, type1 param2, type1 param3)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1, type1 param2, type1 param3)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
param2 Name of parameter two.
param3 Name of parameter three.
const1 Name of a constant which can be used in the body.
func Function body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::UNARY;\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1)\
    {\
        func\
    }\
    __device__ type1 CU(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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
func Function body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::UNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + "dummy" + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1)\
    {\
        func\
    }\
    __device__ type1 CU(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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
func Function body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::UNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + "dummy" + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
func Function body.
#define UNARY_FUNC (   name,
  type1,
  param1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    name()\
    {\
        funcType = skepu::UNARY;\
    }\
    type1 dummy;\
    type1 getConstant() {return dummy;}\
    type1 CPU(type1 param1)\
    {\
        func\
    }\
};

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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
func Function body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  const1,
  func 
)
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)\
    {\
        func\
    }\
};

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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
const1 Name of a constant which can be used in the body.
func Function body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  const1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::UNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #const1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 const1;\
    type1 getConstant() {return const1;}\
    void setConstant(type1 _v) {const1 = _v;}\
    type1 CPU(type1 param1)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
const1 Name of a constant which can be used in the body.
func Function body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  const1,
  func 
)
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)\
    {\
        func\
    }\
    __device__ type1 CU(type1 param1)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
const1 Name of a constant which can be used in the body.
func Function body.
#define UNARY_FUNC_CONSTANT (   name,
  type1,
  param1,
  const1,
  func 
)
Value:
struct name\
{\
    skepu::FuncType funcType;\
    std::string func_CL;\
    std::string funcName_CL;\
    std::string datatype_CL;\
    name()\
    {\
        funcType = skepu::UNARY;\
        funcName_CL.append(#name);\
        datatype_CL.append(#type1);\
        func_CL.append(\
        datatype_CL + " " + funcName_CL + "(" + datatype_CL + " " + #param1 + ", " + datatype_CL + " " + #const1 + ")\n"\
        "{\n"\
        "   " #func "\n"\
        "}\n");\
    }\
    type1 const1;\
    type1 getConstant() {return const1;}\
    void setConstant(type1 _v) {const1 = _v;}\
    type1 CPU(type1 param1)\
    {\
        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:
name Function name.
type1 Type of function parameters.
param1 Name of parameter one.
const1 Name of a constant which can be used in the body.
func Function body.
 All Classes Namespaces Files Functions Enumerations Friends Defines