command_queue
A valid command-queue. The kernel will be queued for execution on the
device associated with command_queue.
kernel
A valid kernel object. The OpenCL context associated with kernel and command_queue must be the same.
num_events_in_wait_list
and event_wait_list
Specify events that need to complete before this
particular command can be executed. If event_wait_list is NULL, then this particular command
does not wait on any event to complete. If event_wait_list is NULL, num_events_in_wait_list must be 0. If event_wait_list is not NULL, the list of events pointed to by event_wait_list must be valid and num_events_in_wait_list must be greater than 0. The events specified in event_wait_list act as synchronization points. The context associated with events in event_wait_list and command_queue must be the same.
event
Returns an event object that identifies this particular kernel execution instance. Event objects are unique and can be used to identify a particular kernel execution instance later on. If event is NULL, no event will be created for this kernel execution instance and therefore it will not be possible for the application to query or queue a wait for this particular kernel execution instance.
The kernel is executed using a single work-item.
clEnqueueTask is equivalent to calling clEnqueueNDRangeKernel with work_dim = 1,
global_work_offset = NULL, global_work_size[0] set to 1, and local_work_size[0] set to 1.
Returns CL_SUCCESS if the kernel execution was successfully queued, or one of the errors below:
command_queue.
command_queue is not a valid command-queue.
kernel is not a valid kernel object.
command_queue
and kernel is not the same or if the context associated with command_queue
and events in event_wait_list are not the same.
kernel using the __attribute__((reqd_work_group_size(X, Y, Z))) qualifier in program source and is not (1, 1, 1).
offset specified when the sub-buffer object
is created is not aligned to CL_DEVICE_MEM_BASE_ADDR_ALIGN value for device associated with queue.
queue.
kernel on the command-queue because of insufficient resources needed to execute the kernel.
kernel.
event_wait_list is NULL
and num_events_in_wait_list is greater than 0, or event_wait_list is not
NULL and num_events_in_wait_list is 0, or if event objects in event_wait_list
are not valid events.
Copyright © 2007-2010 The Khronos Group Inc.
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and/or associated documentation files (the
"Materials"), to deal in the Materials without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Materials, and to
permit persons to whom the Materials are furnished to do so, subject to
the condition that this copyright notice and permission notice shall be included
in all copies or substantial portions of the Materials.