iris: Increase the maximum grid size
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 17 Nov 2022 20:20:30 +0000 (12:20 -0800)
committerMarge Bot <emma+marge@anholt.net>
Fri, 18 Nov 2022 00:53:21 +0000 (00:53 +0000)
I had simply copied these values from another driver when adding initial
compute support to iris.  The actual hardware limit is UINT32_MAX (see
the GPGPU_WALKER/COMPUTE_WALKER ThreadGroupID{X,Y,Z}Dimension fields).

Thanks to Karol Herbst for noticing the unnecessarily low limit.

References: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7676
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Tested-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19826>

src/gallium/drivers/iris/iris_screen.c

index a8e8c38..500fec8 100644 (file)
@@ -574,7 +574,7 @@ iris_get_compute_param(struct pipe_screen *pscreen,
       RET((uint64_t []) { 3 });
 
    case PIPE_COMPUTE_CAP_MAX_GRID_SIZE:
-      RET(((uint64_t []) { 65535, 65535, 65535 }));
+      RET(((uint64_t []) { UINT32_MAX, UINT32_MAX, UINT32_MAX }));
 
    case PIPE_COMPUTE_CAP_MAX_BLOCK_SIZE:
       /* MaxComputeWorkGroupSize[0..2] */