anv/blorp: Make sure blorp type is supported by the queue
authorJordan Justen <jordan.l.justen@intel.com>
Wed, 4 Aug 2021 09:40:17 +0000 (02:40 -0700)
committerMarge Bot <eric+marge@anholt.net>
Thu, 30 Sep 2021 17:41:33 +0000 (17:41 +0000)
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11564>

src/intel/vulkan/genX_blorp_exec.c

index 087361a..721cdb3 100644 (file)
@@ -254,6 +254,10 @@ genX(blorp_exec)(struct blorp_batch *batch,
                  const struct blorp_params *params)
 {
    struct anv_cmd_buffer *cmd_buffer = batch->driver_batch;
+   if (batch->flags & BLORP_BATCH_USE_COMPUTE)
+      assert(cmd_buffer->pool->queue_family->queueFlags & VK_QUEUE_COMPUTE_BIT);
+   else
+      assert(cmd_buffer->pool->queue_family->queueFlags & VK_QUEUE_GRAPHICS_BIT);
 
    if (!cmd_buffer->state.current_l3_config) {
       const struct intel_l3_config *cfg =