All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
error.hpp File Reference

Error handling for the OpenCL layer of ViennaCL. More...

`#include <CL/cl.h>`
`#include <string>`
`#include <iostream>`
`#include <exception>`
`#include <stdexcept>`

Go to the source code of this file.

## Classes

class | viennacl::ocl::queue_not_found
class | viennacl::ocl::program_not_found
class | viennacl::ocl::kernel_not_found
class | viennacl::ocl::device_not_found
| Exception thrown in the case that a requested compute device was not found. More...
class | viennacl::ocl::device_not_available
| Exception thrown if the selected compute device is not available (maybe locked by another process). More...
class | viennacl::ocl::compiler_not_available
| Exception thrown if the OpenCL just-in-time compiler is not available. More...
class | viennacl::ocl::mem_object_allocation_failure
| Exception thrown if a memory object cannot be allocated. Usually the requested memory buffer is simply too large. More...
class | viennacl::ocl::out_of_resources
| Exception thrown if the compute device is out of resources (either global memory, registers, etc.) for the requested operation. More...
class | viennacl::ocl::out_of_host_memory
| Exception thrown if the host cannot provide enough memory for the datastructures in the OpenCL backend (temporary arrays, etc.) to perform the requested operation. More...
class | viennacl::ocl::profiling_info_not_available
| Exception thrown if the OpenCL context does not have CL_QUEUE_PROFILING_ENABLE set, if the execution is not complete, or the event object is a user event object. More...
class | viennacl::ocl::mem_copy_overlap
| Exception thrown if the source buffer overlaps the destination buffer when copying from device memory to device memory. More...
class | viennacl::ocl::image_format_mismatch
| Exception thrown if there is a mismatch in image formats for the operands. More...
class | viennacl::ocl::image_format_not_supported
| Exception thrown if the requested image format is not supported. More...
class | viennacl::ocl::build_program_failure
| Exception thrown if the OpenCL program cannot be built, usually due to a syntax error in the OpenCL code. More...
class | viennacl::ocl::map_failure
| Exception thrown if the mapping of device memory to the host memory space failed. More...
class | viennacl::ocl::invalid_value
| Exception thrown is an invalid value is provided to an OpenCL function. More...
class | viennacl::ocl::invalid_device_type
| Exception thrown if an invalid device type is specified. More...
class | viennacl::ocl::invalid_platform
| Exception thrown if an invalid OpenCL platform is provided to an OpenCL function. More...
class | viennacl::ocl::invalid_device
| Exception thrown if an invalid OpenCL device is provided to an OpenCL function. More...
class | viennacl::ocl::invalid_context
| Exception thrown if an invalid OpenCL context is provided to an OpenCL function. More...
class | viennacl::ocl::invalid_queue_properties
| Exception thrown if invalid OpenCL command queue properties are provided when creating a command queue. More...
class | viennacl::ocl::invalid_command_queue
| Exception thrown if an invalid OpenCL command queue is provided to an OpenCL function. More...
class | viennacl::ocl::invalid_host_ptr
| Exception thrown if the provided pointer to host memory is invalid. More...
class | viennacl::ocl::invalid_mem_object
| Exception thrown if an invalid OpenCL memory object (of type cl_mem) is passed to an OpenCL funciton. More...
class | viennacl::ocl::invalid_image_format_descriptor
| Exception thrown if an invalid image format descriptor is provided. More...
class | viennacl::ocl::invalid_image_size
| Exception thrown if the image size provided is invalid (e.g. zero). More...
class | viennacl::ocl::invalid_sampler
| Exception thrown if an invalid sampler is provided for an image. More...
class | viennacl::ocl::invalid_binary
| Exception thrown if the OpenCL binary (generated from the jit-compiler or loaded from some other location) won't work on the device (e.g. due to a lack of double precision support). More...
class | viennacl::ocl::invalid_build_options
| Exception thrown if invalid build options are passed to the OpenCL just-in-time compiler. More...
class | viennacl::ocl::invalid_program
| Exception thrown if an OpenCL program object handle is invalid (e.g. not initialized). More...
class | viennacl::ocl::invalid_program_executable
| Exception thrown if there is no built program exectuable available for the device. More...
class | viennacl::ocl::invalid_kernel_name
| Exception thrown if the provided kernel name is invalid (e.g. not part of the program provided). More...
class | viennacl::ocl::invalid_kernel_definition
| Exception thrown if the kernel definition (number of arguments, argument types, etc.) is not the same for all devices for which the program has been built. More...
class | viennacl::ocl::invalid_kernel
| Exception thrown if the provided kernel object (of type cl_kernel) is invalid (e.g. not initialized, from different context, or corrupted). More...
class | viennacl::ocl::invalid_arg_index
| Exception thrown if the kernel argument index is invalid, e.g. an arg index larger than the number of kernel arguments was provided. More...
class | viennacl::ocl::invalid_arg_value
| Exception thrown if the kernel argument provided has an invalid value. More...
class | viennacl::ocl::invalid_arg_size
| Exception thrown if the arguments to an OpenCL kernel have an invalid size e.g. not sizeof(cl_mem)). More...
class | viennacl::ocl::invalid_kernel_args
| Exception thrown if the kernel arguments are invalid and/or do not fit the kernel parameter list. More...
class | viennacl::ocl::invalid_work_dimension
| Exception thrown if the work dimension is invalid (usually this means that the work dimension was set to be larger than three. More...
class | viennacl::ocl::invalid_work_group_size
| Exception thrown if the number of work groups is invalid (usually this means that more than 256/512/768/1024 work groups have been specified, but the device(s) cannot support this. More...
class | viennacl::ocl::invalid_work_item_size
| Exception thrown if the number of work items per work group invalid (usually this means that more than 256/512/768/1024 work items have been specified, but the device(s) cannot support this. More...
class | viennacl::ocl::invalid_global_offset
| Exception thrown if the provided offset for get_global_id() in OpenCL kernels is invalid. More...
class | viennacl::ocl::invalid_event_wait_list
| Exception thrown if the provided event wait list is invalid. More...
class | viennacl::ocl::invalid_event
| Exception thrown if the provided event object (of type cl_event) is invalid. More...
class | viennacl::ocl::invalid_operation
| Exception thrown if interoperability of OpenCL with other frameworks collide. More...
class | viennacl::ocl::invalid_gl_object
| Exception thrown if the provided OpenGL (not OpenCL) object is invalid. More...
class | viennacl::ocl::invalid_buffer_size
| Exception thrown if the provided buffer size is invalid (e.g. zero) More...
class | viennacl::ocl::invalid_mip_level
| Exception thrown if the provided miplevel is greater than zero, but the OpenGL implementation does not support creating from non-zero mipmap levels. More...
class | viennacl::ocl::invalid_global_work_size
| Exception thrown if the total number of work items is invalid (for example, not divisible by the number of work items per work group). More...
class | viennacl::ocl::invalid_property
| Exception thrown if an invalid property is provided to a function (vague value). More...
class | viennacl::ocl::unknown_error
| Exception thrown if the returned error cannot be resolved to some defined error constant. Might result from invalid sources, invalid memory operations, etc. More...
class | viennacl::ocl::double_precision_not_provided_error
| Exception thrown if the user wants to use double precision arithmetics, but the device does not support double precision. More...
struct | viennacl::ocl::error_checker< T >
| An error reporting class. Template argument is used to avoid problems with external linkage. More...

## Namespaces

| viennacl
| Main namespace in ViennaCL. Holds all the basic types such as vector, matrix, etc. and defines operations upon them.
| viennacl::ocl
| OpenCL backend. Manages platforms, contexts, buffers, kernels, etc.

## Macros

#define | VIENNACL_BUG_REPORT_STRING
#define | VIENNACL_ERR_CHECK(err) viennacl::ocl::error_checker<void>::checkError(err, __FILE__, __FUNCTION__, __LINE__);

## Detailed Description

Error handling for the OpenCL layer of ViennaCL.

Definition in file error.hpp.

## Macro Definition Documentation

#define VIENNACL_BUG_REPORT_STRING

Value:
"\nIf you think that this is a bug in ViennaCL, please report it at viennacl-support@lists.sourceforge.net and supply at least the following information:\n"\
" * Operating System\n"\
" * Which OpenCL implementation (AMD, NVIDIA, etc.)\n"\
" * ViennaCL version\n"\
"Many thanks in advance!";\

Definition at line 52 of file error.hpp.

#define VIENNACL_ERR_CHECK | ( |  | err | ) | viennacl::ocl::error_checker<void>::checkError(err, __FILE__, __FUNCTION__, __LINE__);

Examples:
  custom-context.cpp.

Definition at line 681 of file error.hpp.