From d70b76ea71045d18361eec4b9615f7708bec005a Mon Sep 17 00:00:00 2001 From: Kenneth Graunke Date: Mon, 15 Aug 2022 18:13:41 -0700 Subject: [PATCH] iris: Enable HiZ for non-8x4 aligned miplevels on Icelake and later 8x4 alignment was absolutely required prior to Gfx8, and while some things were relaxed on Gfx8-9, Nanley's experiments in issue #3788 indicated that there were still issues on those platforms. It appears that the restrictions were relaxed on Icelake and non-8x4 aligned HiZ "should" work on Gfx11+. Reviewed-by: Nanley Chery Part-of: --- src/gallium/drivers/iris/iris_resolve.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/iris/iris_resolve.c b/src/gallium/drivers/iris/iris_resolve.c index cee24f9f438..59e63904eab 100644 --- a/src/gallium/drivers/iris/iris_resolve.c +++ b/src/gallium/drivers/iris/iris_resolve.c @@ -644,8 +644,11 @@ iris_resource_level_has_hiz(const struct intel_device_info *devinfo, /* Disable HiZ for LOD > 0 unless the width/height are 8x4 aligned. * For LOD == 0, we can grow the dimensions to make it work. + * + * This doesn't appear to be necessary on Gfx11+. See details here: + * https://gitlab.freedesktop.org/mesa/mesa/-/issues/3788 */ - if (level > 0) { + if (devinfo->ver < 11 && level > 0) { if (u_minify(res->base.b.width0, level) & 7) return false;