Mesa (master): clover: add CL 3.0 event/queue queries

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Nov 16 19:55:35 UTC 2020


Module: Mesa
Branch: master
Commit: c5a33ed8c20724cd1be0451d4f3fd9f6da047b03
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=c5a33ed8c20724cd1be0451d4f3fd9f6da047b03

Author: Dave Airlie <airlied at redhat.com>
Date:   Thu Oct  8 04:49:46 2020 +1000

clover: add CL 3.0 event/queue queries

Reviewed-by: Karol Herbst <kherbst at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7642>

---

 src/gallium/frontends/clover/api/event.cpp | 1 +
 src/gallium/frontends/clover/api/queue.cpp | 9 +++++++++
 2 files changed, 10 insertions(+)

diff --git a/src/gallium/frontends/clover/api/event.cpp b/src/gallium/frontends/clover/api/event.cpp
index 3f89644d0a4..e1fd9356aa6 100644
--- a/src/gallium/frontends/clover/api/event.cpp
+++ b/src/gallium/frontends/clover/api/event.cpp
@@ -272,6 +272,7 @@ clGetEventProfilingInfo(cl_event d_ev, cl_profiling_info param,
       break;
 
    case CL_PROFILING_COMMAND_END:
+   case CL_PROFILING_COMMAND_COMPLETE:
       buf.as_scalar<cl_ulong>() = hev.time_end();
       break;
 
diff --git a/src/gallium/frontends/clover/api/queue.cpp b/src/gallium/frontends/clover/api/queue.cpp
index 39de311b34f..9d1123b2ddb 100644
--- a/src/gallium/frontends/clover/api/queue.cpp
+++ b/src/gallium/frontends/clover/api/queue.cpp
@@ -98,6 +98,15 @@ clGetCommandQueueInfo(cl_command_queue d_q, cl_command_queue_info param,
       buf.as_vector<cl_queue_properties>() = q.properties();
       break;
 
+   case CL_QUEUE_DEVICE_DEFAULT:
+      if (r_size)
+	 *r_size = 0;
+      break;
+
+   case CL_QUEUE_SIZE:
+      throw error(CL_INVALID_COMMAND_QUEUE);
+      break;
+
    default:
       throw error(CL_INVALID_VALUE);
    }



More information about the mesa-commit mailing list