Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] View of /branches/vis12-cl/src/compiler/cl-target/fragments/c-check-cl-status.in
ViewVC logotype

View of /branches/vis12-cl/src/compiler/cl-target/fragments/c-check-cl-status.in

Parent Directory Parent Directory | Revision Log Revision Log

Revision 3130 - (download) (annotate)
Wed Mar 25 10:40:27 2015 UTC (5 years, 8 months ago) by jhr
File size: 562 byte(s)
  adding better error reporting for OpenCL
// Report an OpenCL error
STATIC_INLINE void ReportOCLError (@PREFIX@World_t *wrld, cl_int sts, const char *msg)
    biffMsgAddf (wrld->errors, "%s: %s (%d)", msg, Diderot_OCLErrorString(sts), sts);

// Check the return status of a CL API call.  If there is an error, add a message to
// the biff buffer and return true, otherwise return false.
STATIC_INLINE bool CheckOCLStatus (@PREFIX@World_t *wrld, cl_int sts, const char *msg)
    if (sts != CL_SUCCESS) {
        ReportOCLError (wrld, sts, msg);
        return true;
	return false;

ViewVC Help
Powered by ViewVC 1.0.0