summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers
diff options
context:
space:
mode:
authorTom Stellard <[email protected]>2014-08-08 09:32:20 -0400
committerTom Stellard <[email protected]>2014-08-13 14:20:22 -0400
commited3f7eadad1527447df14ee0c33fdf75fcad47b1 (patch)
tree48c5d084335d0936d61b482140369be1bdd418b5 /src/gallium/state_trackers
parenta15088338ebe544efd90bfa7934cb99521488141 (diff)
clover: Flush the command queue in clReleaseCommandQueue()
This is required by the spec. Reviewed-by: Francisco Jerez <[email protected]> CC: "10.2" <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers')
-rw-r--r--src/gallium/state_trackers/clover/api/queue.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/clover/api/queue.cpp b/src/gallium/state_trackers/clover/api/queue.cpp
index a136018fbde..06a28638002 100644
--- a/src/gallium/state_trackers/clover/api/queue.cpp
+++ b/src/gallium/state_trackers/clover/api/queue.cpp
@@ -58,7 +58,11 @@ clRetainCommandQueue(cl_command_queue d_q) try {
CLOVER_API cl_int
clReleaseCommandQueue(cl_command_queue d_q) try {
- if (obj(d_q).release())
+ auto &q = obj(d_q);
+
+ q.flush();
+
+ if (q.release())
delete pobj(d_q);
return CL_SUCCESS;