intel: fix the gen 12 compute shader scratch IDs
authorPaulo Zanoni <paulo.r.zanoni@intel.com>
Fri, 28 Feb 2020 23:16:07 +0000 (15:16 -0800)
committerMarge Bot <eric+marge@anholt.net>
Tue, 3 Mar 2020 00:36:10 +0000 (00:36 +0000)
commit9e5ce30da7fa3f1cc3badfd348e5f8fda1bbacb2
treea9012da10ad19a85c5bd89fab9536ba0ef9412a6
parent1efe139cad150072985db02227be947aec532e2b
intel: fix the gen 12 compute shader scratch IDs

This is the same idea as "intel: fix the gen 11 compute shader scratch
IDs".

The number of EUs on TGL is not the same as ICL, but the
MEDIA_VFE_STATE restrictions stay the same, so adapt the code to it.
Also, consider the base configuration instead of what we read from the
Kernel.

According to Mark, this fixes the following piglit tests on TGL:

    piglit.spec.arb_compute_shader.execution.shared-atomicmax-uint.tglm64
    piglit.spec.arb_compute_shader.execution.shared-atomicmax-int.tglm64
    piglit.spec.intel_shader_atomic_float_minmax.execution.shared-atomicmax-float.tglm64

v2: s/ICL+/Gen11+/ (Jason).

Cc: mesa-stable@lists.freedesktop.org
Tested-by: Mark Janes <mark.a.janes@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4006>
src/gallium/drivers/iris/iris_program.c
src/intel/vulkan/anv_allocator.c