[PATCH i-g-t 2/3] lib/intel_batchbuffer: Select xe2 rendercopy for LunarLake
Matthew Auld
matthew.william.auld at gmail.com
Wed Jan 10 11:25:18 UTC 2024
Hi,
On Mon, 8 Jan 2024 at 11:36, Zbigniew Kempczyński
<zbigniew.kempczynski at intel.com> wrote:
>
> Along with rendercopy xe2 pipeline / shader selection for LunarLake
> reorganize if/else conditionals to handle specific selection first.
>
> Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
> Cc: Juha-Pekka Heikkila <juhapekka.heikkila at gmail.com>
> ---
> lib/intel_batchbuffer.c | 38 ++++++++++++++++++++------------------
> 1 file changed, 20 insertions(+), 18 deletions(-)
>
> diff --git a/lib/intel_batchbuffer.c b/lib/intel_batchbuffer.c
> index ccab55cec7..d374645d99 100644
> --- a/lib/intel_batchbuffer.c
> +++ b/lib/intel_batchbuffer.c
> @@ -656,28 +656,30 @@ igt_render_copyfunc_t igt_get_render_copyfunc(int devid)
> {
> igt_render_copyfunc_t copy = NULL;
>
> - if (IS_GEN2(devid))
> - copy = gen2_render_copyfunc;
> - else if (IS_GEN3(devid))
> - copy = gen3_render_copyfunc;
> - else if (IS_GEN4(devid) || IS_GEN5(devid))
> - copy = gen4_render_copyfunc;
> - else if (IS_GEN6(devid))
> - copy = gen6_render_copyfunc;
> - else if (IS_GEN7(devid))
> - copy = gen7_render_copyfunc;
> - else if (IS_GEN8(devid))
> - copy = gen8_render_copyfunc;
> - else if (IS_GEN9(devid) || IS_GEN10(devid))
> - copy = gen9_render_copyfunc;
> - else if (IS_GEN11(devid))
> - copy = gen11_render_copyfunc;
> + if (IS_METEORLAKE(devid))
> + copy = mtl_render_copyfunc;
> + else if (IS_LUNARLAKE(devid))
> + copy = genxe2_render_copyfunc;
This doesn't work with any xe2? Can we not make this conditional on
graphics version == 20?
> else if (HAS_FLATCCS(devid))
> copy = gen12p71_render_copyfunc;
Should we not not make this a normal platform or graphics version
check? This will also catch all xe2+ platforms that are not LNL, but
have flat_ccs support. I think it is better to just return NULL for
new platforms, that way we get a clear skip in tests using this
instead of seeing job timeouts due to using the wrong shader/kernel.
See VLK-54191 for example. What do you think?
> - else if (IS_METEORLAKE(devid))
> - copy = mtl_render_copyfunc;
> else if (IS_GEN12(devid))
> copy = gen12_render_copyfunc;
> + else if (IS_GEN11(devid))
> + copy = gen11_render_copyfunc;
> + else if (IS_GEN9(devid) || IS_GEN10(devid))
> + copy = gen9_render_copyfunc;
> + else if (IS_GEN8(devid))
> + copy = gen8_render_copyfunc;
> + else if (IS_GEN7(devid))
> + copy = gen7_render_copyfunc;
> + else if (IS_GEN6(devid))
> + copy = gen6_render_copyfunc;
> + else if (IS_GEN4(devid) || IS_GEN5(devid))
> + copy = gen4_render_copyfunc;
> + else if (IS_GEN3(devid))
> + copy = gen3_render_copyfunc;
> + else if (IS_GEN2(devid))
> + copy = gen2_render_copyfunc;
>
> return copy;
> }
> --
> 2.34.1
>
More information about the igt-dev
mailing list