summaryrefslogtreecommitdiff
path: root/get_global_id_2d.c
diff options
context:
space:
mode:
Diffstat (limited to 'get_global_id_2d.c')
-rw-r--r--get_global_id_2d.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/get_global_id_2d.c b/get_global_id_2d.c
index 04aa309..47681a3 100644
--- a/get_global_id_2d.c
+++ b/get_global_id_2d.c
@@ -36,15 +36,13 @@ int main (int argc, char ** argv)
return EXIT_FAILURE;
}
- error = clEnqueueNDRangeKernel(context.command_queue,
+ if (!clSimpleEnqueueNDRangeKernel(context.command_queue,
context.kernel,
- 2, /* dimensions */
- NULL,
+ 2,
global_work_size,
- local_work_size,
- 0, NULL, NULL);
-
- assert(error == CL_SUCCESS);
+ local_work_size)) {
+ return EXIT_FAILURE;
+ }
error = clEnqueueReadBuffer(context.command_queue,
out_buffer,