cf4ocl (C Framework for OpenCL)
v2.1.0
Object-oriented framework for developing and benchmarking OpenCL projects in C/C++
|
Base class for all OpenCL wrappers. More...
Public Member Functions | |
CCLWrapperInfo * | ccl_wrapper_get_info (CCLWrapper *wrapper1, CCLWrapper *wrapper2, cl_uint param_name, size_t min_size, CCLInfo info_type, cl_bool use_cache, CCLErr **err) |
Get information about any wrapped OpenCL object. More... | |
size_t | ccl_wrapper_get_info_size (CCLWrapper *wrapper1, CCLWrapper *wrapper2, cl_uint param_name, size_t min_size, CCLInfo info_type, cl_bool use_cache, CCLErr **err) |
Get information size. More... | |
void * | ccl_wrapper_get_info_value (CCLWrapper *wrapper1, CCLWrapper *wrapper2, cl_uint param_name, size_t min_size, CCLInfo info_type, cl_bool use_cache, CCLErr **err) |
Get pointer to information value. More... | |
cl_bool | ccl_wrapper_memcheck () |
Debug function which checks if memory allocated by wrappers has been properly freed. More... | |
void | ccl_wrapper_ref (CCLWrapper *wrapper) |
Increase the reference count of the wrapper object. More... | |
int | ccl_wrapper_ref_count (CCLWrapper *wrapper) |
Returns the wrapper object reference count. More... | |
void * | ccl_wrapper_unwrap (CCLWrapper *wrapper) |
Get the wrapped OpenCL object. More... | |
Base class for all OpenCL wrappers.
Definition at line 47 of file _ccl_abstract_wrapper.h.
CCLWrapperInfo * ccl_wrapper_get_info | ( | CCLWrapper * | wrapper1, |
CCLWrapper * | wrapper2, | ||
cl_uint | param_name, | ||
size_t | min_size, | ||
CCLInfo | info_type, | ||
cl_bool | use_cache, | ||
CCLErr ** | err | ||
) |
Get information about any wrapped OpenCL object.
This function should not be directly invoked in most circumstances. Use the ccl_*_get_info_*()
macros instead.
[in] | wrapper1 | The wrapper object to query. |
[in] | wrapper2 | A second wrapper object, required in some queries. |
[in] | param_name | Name of information/parameter to get. |
[in] | min_size | Minimum size of returned information object in case of error. |
[in] | info_type | Type of information query to perform. |
[in] | use_cache | TRUE if cached information is to be used, FALSE to force a new query even if information is in cache. |
[out] | err | Return location for a CCLErr object, or NULL if error reporting is to be ignored. |
NULL
(if min_size
== 0), or a min_size
d information object is returned (if min_size
> 0). Definition at line 463 of file ccl_abstract_wrapper.c.
size_t ccl_wrapper_get_info_size | ( | CCLWrapper * | wrapper1, |
CCLWrapper * | wrapper2, | ||
cl_uint | param_name, | ||
size_t | min_size, | ||
CCLInfo | info_type, | ||
cl_bool | use_cache, | ||
CCLErr ** | err | ||
) |
Get information size.
This function should not be directly invoked in most circumstances.
[in] | wrapper1 | The wrapper object to query. |
[in] | wrapper2 | A second wrapper object, required in some queries. |
[in] | param_name | Name of information/parameter to get value of. |
[in] | min_size | Minimum size returned in case of error. |
[in] | info_type | Type of information query to perform. |
[in] | use_cache | TRUE if cached information is to be used, FALSE to force a new query even if information is in cache. |
[out] | err | Return location for a CCLErr object, or NULL if error reporting is to be ignored. |
min_size
is returned. Definition at line 641 of file ccl_abstract_wrapper.c.
void * ccl_wrapper_get_info_value | ( | CCLWrapper * | wrapper1, |
CCLWrapper * | wrapper2, | ||
cl_uint | param_name, | ||
size_t | min_size, | ||
CCLInfo | info_type, | ||
cl_bool | use_cache, | ||
CCLErr ** | err | ||
) |
Get pointer to information value.
This function should not be directly invoked in most circumstances. Use the ccl_*_get_info_*()
macros instead.
[in] | wrapper1 | The wrapper object to query. |
[in] | wrapper2 | A second wrapper object, required in some queries. |
[in] | param_name | Name of information/parameter to get value of. |
[in] | min_size | Minimum size of returned value in case of error. |
[in] | info_type | Type of information query to perform. |
[in] | use_cache | TRUE if cached information is to be used, FALSE to force a new query even if information is in cache. |
[out] | err | Return location for a CCLErr object, or NULL if error reporting is to be ignored. |
NULL
(if min_size
== 0), or a pointer to a min_size
d zero value is returned (if min_size
> 0). Definition at line 600 of file ccl_abstract_wrapper.c.
cl_bool ccl_wrapper_memcheck | ( | ) |
Debug function which checks if memory allocated by wrappers has been properly freed.
This function is merely a debug helper and shouldn't replace proper leak checks with Valgrind or similar tool.
Definition at line 675 of file ccl_abstract_wrapper.c.
void ccl_wrapper_ref | ( | CCLWrapper * | wrapper | ) |
Increase the reference count of the wrapper object.
[in] | wrapper | The wrapper object. |
Definition at line 382 of file ccl_abstract_wrapper.c.
int ccl_wrapper_ref_count | ( | CCLWrapper * | wrapper | ) |
Returns the wrapper object reference count.
For debugging and testing purposes only.
[in] | wrapper | The wrapper object. |
Definition at line 410 of file ccl_abstract_wrapper.c.
void * ccl_wrapper_unwrap | ( | CCLWrapper * | wrapper | ) |
Get the wrapped OpenCL object.
[in] | wrapper | The wrapper object. |
Definition at line 429 of file ccl_abstract_wrapper.c.