...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
boost::compute::context_error — A run-time OpenCL context error.
// In header: <boost/compute/exception/context_error.hpp> class context_error : public std::exception { public: // construct/copy/destruct context_error(const context *, const char *, const void *, size_t); ~context_error(); // public member functions const char * what() const; const context * get_context_ptr() const; const void * get_private_info_ptr() const; size_t get_private_info_size() const; };
The context_error exception is thrown when the OpenCL context encounters an error condition. Boost.Compute is notified of these error conditions by registering an error handler when creating context objects (via the pfn_notify
argument to the clCreateContext()
function).
This exception is different than the opencl_error exception which is thrown as a result of error caused when calling a single OpenCL API function.
See Also:
context_error
public member functionsconst char * what() const;Returns a string with a description of the error.
const context * get_context_ptr() const;
Returns a pointer to the context object which generated the error notification.
const void * get_private_info_ptr() const;Returns a pointer to the private info memory block.
size_t get_private_info_size() const;Returns the size of the private info memory block.