Add openCL event support.
authorYang Rong <rong.r.yang@intel.com>
Mon, 12 Aug 2013 08:07:20 +0000 (16:07 +0800)
committerZhigang Gong <zhigang.gong@linux.intel.com>
Mon, 12 Aug 2013 08:36:06 +0000 (16:36 +0800)
commit645a3895a01501aea55b99e5c87e9a25519454c6
treedb2d8bce6b93833f1d5bad94854f79ab0958479c
parentaaf25db296089f5ccde26713b0d3d3ab09b46bcc
Add openCL event support.

Now use the defer execute to wait events.
If there is no user event waited, then using wait rendering to wait
GPU event complete and call the enqueue api immediately.
If there is the user events waited, then should prepare the the enqueue
data, and resume the enqueue when all user events that waited complete.
The achieve these, add the enqueue callback to user event, and add the all
user event and other wait event list to enqueue callback. When set user event
to complete, check all enqueue callbacks wait this event.

Now, clEnqueueMark/clEnqueueBarrier still not impletement, and clEnqueueMapBuffer
/clEnqueueMapImage is not consistency with spec.

Signed-off-by: Yang Rong <rong.r.yang@intel.com>
Reviewed-by: Zhigang Gong <zhigang.gong@linux.intel.com>
src/cl_api.c
src/cl_command_queue_gen7.c
src/cl_context.h
src/cl_event.c
src/cl_event.h
src/cl_internals.h
src/cl_utils.h